[llvm-commits] CVS: llvm/docs/WritingAnLLVMPass.html

2007-06-07 Thread Tanya Lattner


Changes in directory llvm/docs:

WritingAnLLVMPass.html updated: 1.61 - 1.62
---
Log message:

Correct typo. Should be not allowed


---
Diffs of the changes:  (+2 -2)

 WritingAnLLVMPass.html |4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)


Index: llvm/docs/WritingAnLLVMPass.html
diff -u llvm/docs/WritingAnLLVMPass.html:1.61 
llvm/docs/WritingAnLLVMPass.html:1.62
--- llvm/docs/WritingAnLLVMPass.html:1.61   Fri May 18 00:38:44 2007
+++ llvm/docs/WritingAnLLVMPass.htmlThu Jun  7 11:44:52 2007
@@ -537,7 +537,7 @@
 li... emnot allowed/em to modify any ttFunction/tts that are not in
 the current SCC./li
 
-li... emallowed/em to inspect any Function's other than those in the
+li... emnot allowed/em to inspect any Function's other than those in the
 current SCC and the direct callees of the SCC./li
 
 li... emrequired/em to preserve the current CallGraph object, updating it
@@ -1809,7 +1809,7 @@
 
   a href=mailto:[EMAIL PROTECTED]Chris Lattner/abr
   a href=http://llvm.org;The LLVM Compiler Infrastructure/abr
-  Last modified: $Date: 2007/05/18 05:38:44 $
+  Last modified: $Date: 2007/06/07 16:44:52 $
 /address
 
 /body



___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits


[llvm-commits] CVS: llvm/docs/WritingAnLLVMPass.html

2007-05-17 Thread Chris Lattner


Changes in directory llvm/docs:

WritingAnLLVMPass.html updated: 1.59 - 1.60
---
Log message:

validation fixes


---
Diffs of the changes:  (+7 -5)

 WritingAnLLVMPass.html |   12 +++-
 1 files changed, 7 insertions(+), 5 deletions(-)


Index: llvm/docs/WritingAnLLVMPass.html
diff -u llvm/docs/WritingAnLLVMPass.html:1.59 
llvm/docs/WritingAnLLVMPass.html:1.60
--- llvm/docs/WritingAnLLVMPass.html:1.59   Wed May  2 20:11:53 2007
+++ llvm/docs/WritingAnLLVMPass.htmlFri May 18 00:36:14 2007
@@ -264,7 +264,7 @@
 
 div class=doc_codepre
  static char ID;
- Hello() : FunctionPass((intptr_t)ID) {}
+ Hello() : FunctionPass((intptr_t)amp;ID) {}
 /pre/divp
 
 p This declares pass identifier used by LLVM to identify pass. This allows 
LLVM to
@@ -485,7 +485,7 @@
 functions.  Because nothing is known about the behavior of ttModulePass/tt
 subclasses, no optimization can be done for their execution. A module pass
 can use function level passes (e.g. dominators) using getAnalysis interface
-tt getAnalysisDominatorTree(Function)/tt. /p 
+tt getAnalysislt;DominatorTreegt;(Function)/tt. /p 
 
 pTo write a correct ttModulePass/tt subclass, derive from
 ttModulePass/tt and overload the ttrunOnModule/tt method with the
@@ -746,7 +746,7 @@
   bvirtual bool/b doInitialization(Loop *, LPPassManager amp;LPM);
 /pre/div
 
-The ttdoInitialization/tt method is designed to do simple initialization 
+pThe ttdoInitialization/tt method is designed to do simple 
initialization 
 type of stuff that does not depend on the functions being processed.  The 
 ttdoInitialization/tt method call is not scheduled to overlap with any 
 other pass executions (thus it should be very fast). LPPassManager 
@@ -1159,7 +1159,7 @@
}
 /pre/div
 
-In above example, runOnFunction for DominatorTree is called by pass manager
+pIn above example, runOnFunction for DominatorTree is called by pass manager
 before returning a reference to the desired pass./p
 
 p
@@ -1797,6 +1797,8 @@
 haven't had time (or multiprocessor machines, thus a reason) to implement this.
 Despite that, we have kept the LLVM passes SMP ready, and you should too./p
 
+/div
+
 !-- *** 
--
 hr
 address
@@ -1807,7 +1809,7 @@
 
   a href=mailto:[EMAIL PROTECTED]Chris Lattner/abr
   a href=http://llvm.org;The LLVM Compiler Infrastructure/abr
-  Last modified: $Date: 2007/05/03 01:11:53 $
+  Last modified: $Date: 2007/05/18 05:36:14 $
 /address
 
 /body



___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits


[llvm-commits] CVS: llvm/docs/WritingAnLLVMPass.html

2007-05-17 Thread Chris Lattner


Changes in directory llvm/docs:

WritingAnLLVMPass.html updated: 1.60 - 1.61
---
Log message:

validation fix


---
Diffs of the changes:  (+2 -2)

 WritingAnLLVMPass.html |4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)


Index: llvm/docs/WritingAnLLVMPass.html
diff -u llvm/docs/WritingAnLLVMPass.html:1.60 
llvm/docs/WritingAnLLVMPass.html:1.61
--- llvm/docs/WritingAnLLVMPass.html:1.60   Fri May 18 00:36:14 2007
+++ llvm/docs/WritingAnLLVMPass.htmlFri May 18 00:38:44 2007
@@ -312,7 +312,7 @@
   bstruct Hello/b : bpublic/b a href=#FunctionPassFunctionPass/a 
{
 
 static char ID;
-Hello() : FunctionPass((intptr_t)ID) {}
+Hello() : FunctionPass((intptr_t)amp;ID) {}
 
 bvirtual bool/b a href=#runOnFunctionrunOnFunction/a(Function 
amp;F) {
   llvm::cerr lt;lt; iHello: /i lt;lt; F.getName() lt;lt; \n;
@@ -1809,7 +1809,7 @@
 
   a href=mailto:[EMAIL PROTECTED]Chris Lattner/abr
   a href=http://llvm.org;The LLVM Compiler Infrastructure/abr
-  Last modified: $Date: 2007/05/18 05:36:14 $
+  Last modified: $Date: 2007/05/18 05:38:44 $
 /address
 
 /body



___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits


[llvm-commits] CVS: llvm/docs/WritingAnLLVMPass.html

2007-05-02 Thread Devang Patel


Changes in directory llvm/docs:

WritingAnLLVMPass.html updated: 1.57 - 1.58
---
Log message:

Use 'static const char' instead of 'static const int'.
Due to darwin gcc bug, one version of darwin linker coalesces 
static const int, which defauts PassID based pass identification.


---
Diffs of the changes:  (+4 -4)

 WritingAnLLVMPass.html |8 
 1 files changed, 4 insertions(+), 4 deletions(-)


Index: llvm/docs/WritingAnLLVMPass.html
diff -u llvm/docs/WritingAnLLVMPass.html:1.57 
llvm/docs/WritingAnLLVMPass.html:1.58
--- llvm/docs/WritingAnLLVMPass.html:1.57   Tue May  1 15:55:38 2007
+++ llvm/docs/WritingAnLLVMPass.htmlWed May  2 16:39:18 2007
@@ -263,7 +263,7 @@
 time./p
 
 div class=doc_codepre
- static const int ID;
+ static const char ID;
  Hello() : FunctionPass((intptr_t)ID) {}
 /pre/divp
 
@@ -285,7 +285,7 @@
 function./p
 
 div class=doc_codepre
-  const int Hello::ID = 0;
+  const char Hello::ID = 0;
 /pre/div
 
 p We initialize pass ID here. LLVM uses ID's address to identify pass so 
@@ -311,7 +311,7 @@
 bnamespace/b {
   bstruct Hello/b : bpublic/b a href=#FunctionPassFunctionPass/a 
{
 
-static const int ID;
+static const char ID;
 Hello() : FunctionPass((intptr_t)ID) {}
 
 bvirtual bool/b a href=#runOnFunctionrunOnFunction/a(Function 
amp;F) {
@@ -1807,7 +1807,7 @@
 
   a href=mailto:[EMAIL PROTECTED]Chris Lattner/abr
   a href=http://llvm.org;The LLVM Compiler Infrastructure/abr
-  Last modified: $Date: 2007/05/01 20:55:38 $
+  Last modified: $Date: 2007/05/02 21:39:18 $
 /address
 
 /body



___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits


[llvm-commits] CVS: llvm/docs/WritingAnLLVMPass.html

2007-05-02 Thread Devang Patel


Changes in directory llvm/docs:

WritingAnLLVMPass.html updated: 1.58 - 1.59
---
Log message:

Drop 'const'


---
Diffs of the changes:  (+4 -4)

 WritingAnLLVMPass.html |8 
 1 files changed, 4 insertions(+), 4 deletions(-)


Index: llvm/docs/WritingAnLLVMPass.html
diff -u llvm/docs/WritingAnLLVMPass.html:1.58 
llvm/docs/WritingAnLLVMPass.html:1.59
--- llvm/docs/WritingAnLLVMPass.html:1.58   Wed May  2 16:39:18 2007
+++ llvm/docs/WritingAnLLVMPass.htmlWed May  2 20:11:53 2007
@@ -263,7 +263,7 @@
 time./p
 
 div class=doc_codepre
- static const char ID;
+ static char ID;
  Hello() : FunctionPass((intptr_t)ID) {}
 /pre/divp
 
@@ -285,7 +285,7 @@
 function./p
 
 div class=doc_codepre
-  const char Hello::ID = 0;
+  char Hello::ID = 0;
 /pre/div
 
 p We initialize pass ID here. LLVM uses ID's address to identify pass so 
@@ -311,7 +311,7 @@
 bnamespace/b {
   bstruct Hello/b : bpublic/b a href=#FunctionPassFunctionPass/a 
{
 
-static const char ID;
+static char ID;
 Hello() : FunctionPass((intptr_t)ID) {}
 
 bvirtual bool/b a href=#runOnFunctionrunOnFunction/a(Function 
amp;F) {
@@ -1807,7 +1807,7 @@
 
   a href=mailto:[EMAIL PROTECTED]Chris Lattner/abr
   a href=http://llvm.org;The LLVM Compiler Infrastructure/abr
-  Last modified: $Date: 2007/05/02 21:39:18 $
+  Last modified: $Date: 2007/05/03 01:11:53 $
 /address
 
 /body



___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits


[llvm-commits] CVS: llvm/docs/WritingAnLLVMPass.html

2007-05-01 Thread Devang Patel


Changes in directory llvm/docs:

WritingAnLLVMPass.html updated: 1.56 - 1.57
---
Log message:

Update doc to reflect changes I am about to install to fix PR 888: 
http://llvm.org/PR888 .


---
Diffs of the changes:  (+20 -1)

 WritingAnLLVMPass.html |   21 -
 1 files changed, 20 insertions(+), 1 deletion(-)


Index: llvm/docs/WritingAnLLVMPass.html
diff -u llvm/docs/WritingAnLLVMPass.html:1.56 
llvm/docs/WritingAnLLVMPass.html:1.57
--- llvm/docs/WritingAnLLVMPass.html:1.56   Mon Apr 16 19:17:11 2007
+++ llvm/docs/WritingAnLLVMPass.htmlTue May  1 15:55:38 2007
@@ -263,6 +263,14 @@
 time./p
 
 div class=doc_codepre
+ static const int ID;
+ Hello() : FunctionPass((intptr_t)ID) {}
+/pre/divp
+
+p This declares pass identifier used by LLVM to identify pass. This allows 
LLVM to
+avoid using expensive C++ runtime information./p
+
+div class=doc_codepre
 bvirtual bool/b a href=#runOnFunctionrunOnFunction/a(Function 
amp;F) {
   llvm::cerr lt;lt; iHello: /i lt;lt; F.getName() lt;lt; \n;
   breturn false/b;
@@ -277,6 +285,13 @@
 function./p
 
 div class=doc_codepre
+  const int Hello::ID = 0;
+/pre/div
+
+p We initialize pass ID here. LLVM uses ID's address to identify pass so 
+initialization value is not important./p
+
+div class=doc_codepre
   RegisterPasslt;Hellogt; X(ihello/i, iHello World Pass/i);
 }  i// end of anonymous namespace/i
 /pre/div
@@ -295,6 +310,10 @@
 
 bnamespace/b {
   bstruct Hello/b : bpublic/b a href=#FunctionPassFunctionPass/a 
{
+
+static const int ID;
+Hello() : FunctionPass((intptr_t)ID) {}
+
 bvirtual bool/b a href=#runOnFunctionrunOnFunction/a(Function 
amp;F) {
   llvm::cerr lt;lt; iHello: /i lt;lt; F.getName() lt;lt; \n;
   breturn false/b;
@@ -1788,7 +1807,7 @@
 
   a href=mailto:[EMAIL PROTECTED]Chris Lattner/abr
   a href=http://llvm.org;The LLVM Compiler Infrastructure/abr
-  Last modified: $Date: 2007/04/17 00:17:11 $
+  Last modified: $Date: 2007/05/01 20:55:38 $
 /address
 
 /body



___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits


[llvm-commits] CVS: llvm/docs/WritingAnLLVMPass.html

2007-04-16 Thread Devang Patel


Changes in directory llvm/docs:

WritingAnLLVMPass.html updated: 1.55 - 1.56
---
Log message:

Remove ModulePasses requiring FunctionPasses from the list of future
extensions.


---
Diffs of the changes:  (+2 -29)

 WritingAnLLVMPass.html |   31 ++-
 1 files changed, 2 insertions(+), 29 deletions(-)


Index: llvm/docs/WritingAnLLVMPass.html
diff -u llvm/docs/WritingAnLLVMPass.html:1.55 
llvm/docs/WritingAnLLVMPass.html:1.56
--- llvm/docs/WritingAnLLVMPass.html:1.55   Mon Apr 16 16:28:14 2007
+++ llvm/docs/WritingAnLLVMPass.htmlMon Apr 16 19:17:11 2007
@@ -103,8 +103,6 @@
   lia href=#futureFuture extensions planned/a
 ul
 lia href=#SMPMultithreaded LLVM/a/li
-lia href=#PassFunctionPassttModulePass/ttes requiring 
-ttFunctionPass/ttes/a/li
 /ul/li
 /ol
 
@@ -1137,7 +1135,7 @@
 div class=doc_codepre
bool ModuleLevelPass::runOnModule(Module amp;M) {
  ...
- DominatorTree amp;DT = getAnalysislt;DominatorTreegt;(Function amp;F);
+ DominatorTree amp;DT = getAnalysislt;DominatorTreegt;(Func);
  ...
}
 /pre/div
@@ -1780,31 +1778,6 @@
 haven't had time (or multiprocessor machines, thus a reason) to implement this.
 Despite that, we have kept the LLVM passes SMP ready, and you should too./p
 
-/div
-
-!-- ___ 
--
-div class=doc_subsubsection
-a name=PassFunctionPassttModulePass/ttes requiring 
ttFunctionPass/ttes/a
-/div
-
-div class=doc_text
-
-pCurrently it is illegal for a a href=#ModulePassttModulePass/tt/a
-to require a a href=#FunctionPassttFunctionPass/tt/a.  This is 
because
-there is only one instance of the a
-href=#FunctionPassttFunctionPass/tt/a object ever created, thus 
nowhere
-to store information for all of the functions in the program at the same time.
-Although this has come up a couple of times before, this has always been worked
-around by factoring one big complicated pass into a global and an
-interprocedural part, both of which are distinct.  In the future, it would be
-nice to have this though./p
-
-pNote that it is no problem for a a
-href=#FunctionPassttFunctionPass/tt/a to require the results of a a
-href=#ModulePassttModulePass/tt/a, only the other way around./p
-
-/div
-
 !-- *** 
--
 hr
 address
@@ -1815,7 +1788,7 @@
 
   a href=mailto:[EMAIL PROTECTED]Chris Lattner/abr
   a href=http://llvm.org;The LLVM Compiler Infrastructure/abr
-  Last modified: $Date: 2007/04/16 21:28:14 $
+  Last modified: $Date: 2007/04/17 00:17:11 $
 /address
 
 /body



___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits


[llvm-commits] CVS: llvm/docs/WritingAnLLVMPass.html

2007-03-19 Thread Devang Patel


Changes in directory llvm/docs:

WritingAnLLVMPass.html updated: 1.53 - 1.54
---
Log message:

Document LoopPass.


---
Diffs of the changes:  (+89 -1)

 WritingAnLLVMPass.html |   90 -
 1 files changed, 89 insertions(+), 1 deletion(-)


Index: llvm/docs/WritingAnLLVMPass.html
diff -u llvm/docs/WritingAnLLVMPass.html:1.53 
llvm/docs/WritingAnLLVMPass.html:1.54
--- llvm/docs/WritingAnLLVMPass.html:1.53   Wed Mar 14 14:32:21 2007
+++ llvm/docs/WritingAnLLVMPass.htmlMon Mar 19 17:21:25 2007
@@ -43,6 +43,14 @@
 lia href=#doFinalization_modThe ttdoFinalization(Module
 amp;)/tt method/a/li
 /ul/li
+ lia href=#LoopPassThe ttLoopPass/tt class/a
+ul
+lia href=#doInitialization_loopThe ttdoInitialization(Loop *,
+LPPassManager amp;)/tt 
method/a/li
+lia href=#runOnLoopThe ttrunOnLoop/tt method/a/li
+lia href=#doFinalization_loopThe ttdoFinalization()
+/tt method/a/li
+/ul/li
  lia href=#BasicBlockPassThe ttBasicBlockPass/tt class/a
 ul
 lia href=#doInitialization_fnThe ttdoInitialization(Function
@@ -126,6 +134,7 @@
 the tta href=#ModulePassModulePass/a/tt, tta
 href=#CallGraphSCCPassCallGraphSCCPass/a/tt, tta
 href=#FunctionPassFunctionPass/a/tt, or tta
+href=#LoopPassLoopPass/a/tt, or tta
 href=#BasicBlockPassBasicBlockPass/a/tt classes, which gives the system
 more information about what your pass does, and how it can be combined with
 other passes.  One of the main features of the LLVM Pass Framework is that it
@@ -689,6 +698,85 @@
 
 !-- === 
--
 div class=doc_subsection
+  a name=LoopPassThe ttLoopPass/tt class /a
+/div
+
+div class=doc_text
+
+p All ttLoopPass/tt execute on each loop in the function independent of
+all of the other loops in the function. ttLoopPass/tt processes loops in
+loop nest order such that outer most loop is processed last. /p
+
+p ttLoopPass/tt subclasses are allowed to update loop nest using
+ttLPPassManager/tt interface. Implementing a loop pass is usually
+straightforward. ttLooppass/tt's may overload three virtual methods to
+do their work. All these methods should return true if they modified the 
+program, or false if they didn't. /p
+/div
+
+!-- ___ 
--
+div class=doc_subsubsection
+  a name=doInitialization_loopThe ttdoInitialization(Loop *,
+ LPPassManager amp;)/tt
+  method/a
+/div
+
+div class=doc_text
+
+div class=doc_codepre
+  bvirtual bool/b doInitialization(Loop *, LPPassManager amp;LPM);
+/pre/div
+
+The ttdoInitialization/tt method is designed to do simple initialization 
+type of stuff that does not depend on the functions being processed.  The 
+ttdoInitialization/tt method call is not scheduled to overlap with any 
+other pass executions (thus it should be very fast). LPPassManager 
+interface should be used to access Function or Module level analysis
+information./p
+
+/div
+
+
+!-- ___ 
--
+div class=doc_subsubsection
+  a name=runOnLoopThe ttrunOnLoop/tt method/a
+/div
+
+div class=doc_text
+
+div class=doc_codepre
+  bvirtual bool/b runOnLoop(Loop *, LPPassManager amp;LPM) = 0;
+/pre/divp
+
+pThe ttrunOnLoop/tt method must be implemented by your subclass to do
+the transformation or analysis work of your pass.  As usual, a true value 
should
+be returned if the function is modified. ttLPPassManager/tt interface
+should be used to update loop nest./p
+
+/div
+
+!-- ___ 
--
+div class=doc_subsubsection
+  a name=doFinalization_loopThe ttdoFinalization()/tt method/a
+/div
+
+div class=doc_text
+
+div class=doc_codepre
+  bvirtual bool/b doFinalization();
+/pre/div
+
+pThe ttdoFinalization/tt method is an infrequently used method that is
+called when the pass framework has finished calling a
+href=#runOnLoopttrunOnLoop/tt/a for every loop in the
+program being compiled. /p
+
+/div
+
+
+
+!-- === 
--
+div class=doc_subsection
   a name=BasicBlockPassThe ttBasicBlockPass/tt class/a
 /div
 
@@ -1711,7 +1799,7 @@
 
   a href=mailto:[EMAIL PROTECTED]Chris Lattner/abr
   a href=http://llvm.org;The LLVM Compiler Infrastructure/abr
-  Last modified: $Date: 2007/03/14 19:32:21 $
+  Last modified: $Date: 2007/03/19 22:21:25 $
 /address
 
 /body



___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits


[llvm-commits] CVS: llvm/docs/WritingAnLLVMPass.html

2007-03-14 Thread Jim Laskey


Changes in directory llvm/docs:

WritingAnLLVMPass.html updated: 1.52 - 1.53
---
Log message:

Change e-mail address.

---
Diffs of the changes:  (+2 -2)

 WritingAnLLVMPass.html |4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)


Index: llvm/docs/WritingAnLLVMPass.html
diff -u llvm/docs/WritingAnLLVMPass.html:1.52 
llvm/docs/WritingAnLLVMPass.html:1.53
--- llvm/docs/WritingAnLLVMPass.html:1.52   Tue Jan 23 16:56:28 2007
+++ llvm/docs/WritingAnLLVMPass.htmlWed Mar 14 14:32:21 2007
@@ -102,7 +102,7 @@
 
 div class=doc_author
   pWritten by a href=mailto:[EMAIL PROTECTED]Chris Lattner/a and
-  a href=mailto:[EMAIL PROTECTED]Jim Laskey/a/p
+  a href=mailto:[EMAIL PROTECTED]Jim Laskey/a/p
 /div
 
 !-- *** 
--
@@ -1711,7 +1711,7 @@
 
   a href=mailto:[EMAIL PROTECTED]Chris Lattner/abr
   a href=http://llvm.org;The LLVM Compiler Infrastructure/abr
-  Last modified: $Date: 2007/01/23 22:56:28 $
+  Last modified: $Date: 2007/03/14 19:32:21 $
 /address
 
 /body



___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits


[llvm-commits] CVS: llvm/docs/WritingAnLLVMPass.html

2007-01-23 Thread Devang Patel


Changes in directory llvm/docs:

WritingAnLLVMPass.html updated: 1.51 - 1.52
---
Log message:

Fix cut-n-pasto.


---
Diffs of the changes:  (+7 -7)

 WritingAnLLVMPass.html |   14 +++---
 1 files changed, 7 insertions(+), 7 deletions(-)


Index: llvm/docs/WritingAnLLVMPass.html
diff -u llvm/docs/WritingAnLLVMPass.html:1.51 
llvm/docs/WritingAnLLVMPass.html:1.52
--- llvm/docs/WritingAnLLVMPass.html:1.51   Thu Dec  7 14:04:41 2006
+++ llvm/docs/WritingAnLLVMPass.htmlTue Jan 23 16:56:28 2007
@@ -29,10 +29,10 @@
 /ul/li
  lia href=#CallGraphSCCPassThe ttCallGraphSCCPass/tt class/a
 ul
-lia href=#doInitialization_sccThe ttdoInitialization(Module
+lia href=#doInitialization_sccThe ttdoInitialization(CallGraph
amp;)/tt method/a/li
 lia href=#runOnSCCThe ttrunOnSCC/tt method/a/li
-lia href=#doFinalization_sccThe ttdoFinalization(Module
+lia href=#doFinalization_sccThe ttdoFinalization(CallGraph
amp;)/tt method/a/li
 /ul/li
  lia href=#FunctionPassThe ttFunctionPass/tt class/a
@@ -534,14 +534,14 @@
 
 !-- ___ 
--
 div class=doc_subsubsection
-  a name=doInitialization_sccThe ttdoInitialization(Module amp;)/tt
+  a name=doInitialization_sccThe ttdoInitialization(CallGraph amp;)/tt
   method/a
 /div
 
 div class=doc_text
 
 div class=doc_codepre
-  bvirtual bool/b doInitialization(Module amp;M);
+  bvirtual bool/b doInitialization(CallGraph amp;CG);
 /pre/div
 
 pThe ttdoIninitialize/tt method is allowed to do most of the things that
@@ -573,14 +573,14 @@
 
 !-- ___ 
--
 div class=doc_subsubsection
-  a name=doFinalization_sccThe ttdoFinalization(Module
+  a name=doFinalization_sccThe ttdoFinalization(CallGraph
amp;)/tt method/a
 /div
 
 div class=doc_text
 
 div class=doc_codepre
-  bvirtual bool/b doFinalization(Module amp;M);
+  bvirtual bool/b doFinalization(CallGraph amp;CG);
 /pre/div
 
 pThe ttdoFinalization/tt method is an infrequently used method that is
@@ -1711,7 +1711,7 @@
 
   a href=mailto:[EMAIL PROTECTED]Chris Lattner/abr
   a href=http://llvm.org;The LLVM Compiler Infrastructure/abr
-  Last modified: $Date: 2006/12/07 20:04:41 $
+  Last modified: $Date: 2007/01/23 22:56:28 $
 /address
 
 /body



___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits


[llvm-commits] CVS: llvm/docs/WritingAnLLVMPass.html

2006-09-28 Thread Reid Spencer


Changes in directory llvm/docs:

WritingAnLLVMPass.html updated: 1.49 - 1.50
---
Log message:

Provide a gdb usage fix provided by Zhongzing Xu.


---
Diffs of the changes:  (+2 -2)

 WritingAnLLVMPass.html |4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)


Index: llvm/docs/WritingAnLLVMPass.html
diff -u llvm/docs/WritingAnLLVMPass.html:1.49 
llvm/docs/WritingAnLLVMPass.html:1.50
--- llvm/docs/WritingAnLLVMPass.html:1.49   Sun Aug 27 19:45:38 2006
+++ llvm/docs/WritingAnLLVMPass.htmlThu Sep 28 11:53:47 2006
@@ -1593,7 +1593,7 @@
 want:/p
 
 div class=doc_codepre
-(gdb) bbreak PassManager::run/b
+(gdb) bbreak llvm::PassManager::run/b
 Breakpoint 1 at 0x2413bc: file Pass.cpp, line 70.
 (gdb) brun test.bc -load $(LLVMTOP)/llvm/Debug/lib/[libname].so 
-[passoption]/b
 Starting program: opt test.bc -load $(LLVMTOP)/llvm/Debug/lib/[libname].so 
-[passoption]
@@ -1711,7 +1711,7 @@
 
   a href=mailto:[EMAIL PROTECTED]Chris Lattner/abr
   a href=http://llvm.org;The LLVM Compiler Infrastructure/abr
-  Last modified: $Date: 2006/08/28 00:45:38 $
+  Last modified: $Date: 2006/09/28 16:53:47 $
 /address
 
 /body



___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits


[llvm-commits] CVS: llvm/docs/WritingAnLLVMPass.html

2006-08-27 Thread Chris Lattner


Changes in directory llvm/docs:

WritingAnLLVMPass.html updated: 1.47 - 1.48
---
Log message:

update doc: analyze is gone and passes should just use RegisterPass


---
Diffs of the changes:  (+20 -43)

 WritingAnLLVMPass.html |   63 +++--
 1 files changed, 20 insertions(+), 43 deletions(-)


Index: llvm/docs/WritingAnLLVMPass.html
diff -u llvm/docs/WritingAnLLVMPass.html:1.47 
llvm/docs/WritingAnLLVMPass.html:1.48
--- llvm/docs/WritingAnLLVMPass.html:1.47   Fri Aug 11 11:37:02 2006
+++ llvm/docs/WritingAnLLVMPass.htmlSun Aug 27 18:18:52 2006
@@ -18,8 +18,7 @@
 ul
 lia href=#makefileSetting up the build environment/a/li
 lia href=#basiccodeBasic code required/a/li
-lia href=#runningRunning a pass with ttopt/tt
- or ttanalyze/tt/a/li
+lia href=#runningRunning a pass with ttopt/tt/a/li
 /ul/li
   lia href=#passtypePass classes and requirements/a
  ul
@@ -194,7 +193,7 @@
 pThis makefile specifies that all of the tt.cpp/tt files in the current
 directory are to be compiled and linked together into a
 ttDebug/lib/Hello.so/tt shared object that can be dynamically loaded by
-the ttopt/tt or ttanalyze/tt tools via their tt-load/tt options.  
+the ttopt/tt or ttbugpoint/tt tools via their tt-load/tt options.  
 If your operating system uses a suffix other than .so (such as windows or 
 Mac OS/X), the appropriate extension will be used./p
 
@@ -271,15 +270,13 @@
 function./p
 
 div class=doc_codepre
-  RegisterOptlt;Hellogt; X(ihello/i, iHello World Pass/i);
+  RegisterPasslt;Hellogt; X(ihello/i, iHello World Pass/i);
 }  i// end of anonymous namespace/i
 /pre/div
 
-pLastly, we register our class ttHello/tt, giving it a command line
-argument tthello/tt, and a name ttHello World Pass/tt.  There are
-several different ways of a href=#registrationregistering your pass/a,
-depending on what it is to be used for.  For optimizations we use the
-ttRegisterOpt/tt template./p
+pLastly, we a href=#registrationregister our class/a ttHello/tt, 
+giving it a command line
+argument tthello/tt, and a name ttHello World Pass/tt./p
 
 pAs a whole, the tt.cpp/tt file looks like:/p
 
@@ -297,7 +294,7 @@
 }
   };
   
-  RegisterOptlt;Hellogt; X(ihello/i, iHello World Pass/i);
+  RegisterPasslt;Hellogt; X(ihello/i, iHello World Pass/i);
 }
 /pre/div
 
@@ -312,14 +309,14 @@
 
 !-- === 
--
 div class=doc_subsection
-  a name=runningRunning a pass with ttopt/tt or ttanalyze/tt/a
+  a name=runningRunning a pass with ttopt/tt/a
 /div
 
 div class=doc_text
 
 pNow that you have a brand new shiny shared object file, we can use the
 ttopt/tt command to run an LLVM program through your pass.  Because you
-registered your pass with the ttRegisterOpt/tt template, you will be able 
to
+registered your pass with the ttRegisterPass/tt template, you will be able 
to
 use the ttopt/tt tool to access it, once loaded./p
 
 pTo test it, follow the example at the end of the a
@@ -844,37 +841,17 @@
 pass registration works, and discussed some of the reasons that it is used and
 what it does.  Here we discuss how and why passes are registered./p
 
-pPasses can be registered in several different ways.  Depending on the 
general
-classification of the pass, you should use one of the following templates to
-register the pass:/p
-
-ul
-libttRegisterOpt/tt/b - This template should be used when you are
-registering a pass that logically should be available for use in the
-'ttopt/tt' utility./li
-
-libttRegisterAnalysis/tt/b - This template should be used when you 
are
-registering a pass that logically should be available for use in the
-'ttanalyze/tt' utility./li
-
-libttRegisterPass/tt/b - This is the generic form of the
-ttRegister*/tt templates that should be used if you want your pass listed 
by
-multiple or no utilities.  This template takes an extra third argument that
-specifies which tools it should be listed in.  See the a
-href=http://llvm.org/doxygen/PassSupport_8h-source.html;PassSupport.h/a
-file for more information./li
-
-/ul
-
-pRegardless of how you register your pass, you must specify at least two
+pAs we saw above, passes are registered with the bttRegisterPass/tt/b
+template, which requires you to pass at least two
 parameters.  The first parameter is the name of the pass that is to be used on
 the command line to specify that the pass should be added to a program (for
-example ttopt/tt or ttanalyze/tt).  The second argument is the name of
-the pass, which is to be used for the tt--help/tt output of programs, as
+example, with ttopt/tt or ttbugpoint/tt).  The second argument is the
+name of the pass, which is to be used for the tt--help/tt output of
+programs, as
 well as for debug output generated by the tt--debug-pass/tt option./p
 
-pIf a pass is registered to be used by the ttanalyze/tt utility, you
-should implement the virtual ttprint/tt method:/p
+pIf you want your 

[llvm-commits] CVS: llvm/docs/WritingAnLLVMPass.html

2006-08-11 Thread Chris Lattner


Changes in directory llvm/docs:

WritingAnLLVMPass.html updated: 1.46 - 1.47
---
Log message:

Minor cleanups


---
Diffs of the changes:  (+5 -5)

 WritingAnLLVMPass.html |   10 +-
 1 files changed, 5 insertions(+), 5 deletions(-)


Index: llvm/docs/WritingAnLLVMPass.html
diff -u llvm/docs/WritingAnLLVMPass.html:1.46 
llvm/docs/WritingAnLLVMPass.html:1.47
--- llvm/docs/WritingAnLLVMPass.html:1.46   Mon Aug  7 20:48:17 2006
+++ llvm/docs/WritingAnLLVMPass.htmlFri Aug 11 11:37:02 2006
@@ -102,7 +102,7 @@
 /ol
 
 div class=doc_author
-  pWritten by a href=mailto:[EMAIL PROTECTED]Chris Lattner/a, 
+  pWritten by a href=mailto:[EMAIL PROTECTED]Chris Lattner/a and
   a href=mailto:[EMAIL PROTECTED]Jim Laskey/a/p
 /div
 
@@ -1484,7 +1484,7 @@
 .cpp file add the following include;/p
 
 div class=doc_codepre
-  #include llvm/CodeGen/RegAllocRegistry.h
+  #include llvm/CodeGen/RegAllocRegistry.h
 /pre/div
 
 pAlso in your register allocator .cpp file, define a creator function in the
@@ -1522,8 +1522,8 @@
 
 pAnd that's it.  The user is now free to use tt-regalloc=myregalloc/tt as
 an option.  Registering instruction schedulers is similar except use the
-ttRegisterRegAlloc/tt class.  Note that the
-ttRegisterRegAlloc::FunctionPassCtor/tt is significantly different from
+ttRegisterScheduler/tt class.  Note that the
+ttRegisterScheduler::FunctionPassCtor/tt is significantly different from
 ttRegisterRegAlloc::FunctionPassCtor/tt./p
 
 pTo force the load/linking of your register allocator into the llc/lli tools,
@@ -1734,7 +1734,7 @@
 
   a href=mailto:[EMAIL PROTECTED]Chris Lattner/abr
   a href=http://llvm.org;The LLVM Compiler Infrastructure/abr
-  Last modified: $Date: 2006/08/08 01:48:17 $
+  Last modified: $Date: 2006/08/11 16:37:02 $
 /address
 
 /body



___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits


[llvm-commits] CVS: llvm/docs/WritingAnLLVMPass.html

2006-08-07 Thread Reid Spencer


Changes in directory llvm/docs:

WritingAnLLVMPass.html updated: 1.45 - 1.46
---
Log message:

Update the instructions for writing a pass as a loadable module per the
new definition in MakefileGuilde.html and Makefile.rules.


---
Diffs of the changes:  (+6 -4)

 WritingAnLLVMPass.html |   10 ++
 1 files changed, 6 insertions(+), 4 deletions(-)


Index: llvm/docs/WritingAnLLVMPass.html
diff -u llvm/docs/WritingAnLLVMPass.html:1.45 
llvm/docs/WritingAnLLVMPass.html:1.46
--- llvm/docs/WritingAnLLVMPass.html:1.45   Fri Aug  4 13:10:12 2006
+++ llvm/docs/WritingAnLLVMPass.htmlMon Aug  7 20:48:17 2006
@@ -178,13 +178,15 @@
 # Name of the library to build
 LIBRARYNAME = Hello
 
-# Build a dynamically linkable shared object
-SHARED_LIBRARY = 1
-
 # Make the shared library become a loadable module so the tools can 
 # dlopen/dlsym on the resulting library.
 LOADABLE_MODULE = 1
 
+# Tell the build system which LLVM libraries your pass needs. You'll probably
+# need at least LLVMSystem.a, LLVMSupport.a, LLVMCore.a but possibly several
+# others too.
+LLVMLIBS = LLVMCore.a LLVMSupport.a LLVMSystem.a
+
 # Include the makefile implementation stuff
 include $(LEVEL)/Makefile.common
 /pre/div
@@ -1732,7 +1734,7 @@
 
   a href=mailto:[EMAIL PROTECTED]Chris Lattner/abr
   a href=http://llvm.org;The LLVM Compiler Infrastructure/abr
-  Last modified: $Date: 2006/08/04 18:10:12 $
+  Last modified: $Date: 2006/08/08 01:48:17 $
 /address
 
 /body



___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits


[llvm-commits] CVS: llvm/docs/WritingAnLLVMPass.html

2006-08-04 Thread Jim Laskey


Changes in directory llvm/docs:

WritingAnLLVMPass.html updated: 1.44 - 1.45
---
Log message:

Added how to add machine passes to command line options.


---
Diffs of the changes:  (+217 -78)

 WritingAnLLVMPass.html |  295 -
 1 files changed, 217 insertions(+), 78 deletions(-)


Index: llvm/docs/WritingAnLLVMPass.html
diff -u llvm/docs/WritingAnLLVMPass.html:1.44 
llvm/docs/WritingAnLLVMPass.html:1.45
--- llvm/docs/WritingAnLLVMPass.html:1.44   Mon Mar 13 23:39:39 2006
+++ llvm/docs/WritingAnLLVMPass.htmlFri Aug  4 13:10:12 2006
@@ -83,6 +83,11 @@
 ul
 lia href=#releaseMemoryThe ttreleaseMemory/tt method/a/li
 /ul/li
+  lia href=#registeringRegistering dynamically loaded passes/a
+ul
+  lia href=#registering_existingUsing existing registries/a/li
+  lia href=#registering_newCreating new registries/a/li
+/ul/li
   lia href=#debughintsUsing GDB with dynamically loaded passes/a
 ul
 lia href=#breakpointSetting a breakpoint in your pass/a/li
@@ -97,7 +102,8 @@
 /ol
 
 div class=doc_author
-  pWritten by a href=mailto:[EMAIL PROTECTED]Chris Lattner/a/p
+  pWritten by a href=mailto:[EMAIL PROTECTED]Chris Lattner/a, 
+  a href=mailto:[EMAIL PROTECTED]Jim Laskey/a/p
 /div
 
 !-- *** 
--
@@ -163,7 +169,7 @@
   copy the following into ttMakefile/tt:/p
   hr/
 
-pre
+div class=doc_codepre
 # Makefile for hello pass
 
 # Path to top level of LLVM heirarchy
@@ -181,7 +187,7 @@
 
 # Include the makefile implementation stuff
 include $(LEVEL)/Makefile.common
-/pre
+/pre/div
 
 pThis makefile specifies that all of the tt.cpp/tt files in the current
 directory are to be compiled and linked together into a
@@ -205,10 +211,10 @@
 pNow that we have a way to compile our new pass, we just have to write it.
 Start out with:/p
 
-pre
+div class=doc_codepre
 b#include/b a 
href=http://llvm.org/doxygen/Pass_8h-source.html;llvm/Pass.h/a
 b#include/b a 
href=http://llvm.org/doxygen/Function_8h-source.html;llvm/Function.h/a
-/pre
+/pre/div
 
 pWhich are needed because we are writing a tta
 href=http://llvm.org/doxygen/classllvm_1_1Pass.html;Pass/a/tt, and
@@ -216,18 +222,18 @@
 
href=http://llvm.org/doxygen/classllvm_1_1Function.html;Function/a/tt's./p
 
 pNext we have:/p
-pre
+div class=doc_codepre
 busing namespace llvm;/b
-/pre
+/pre/div
 p... which is required because the functions from the include files 
 live in the llvm namespace.
 /p
 
 pNext we have:/p
 
-pre
+div class=doc_codepre
 bnamespace/b {
-/pre
+/pre/div
 
 p... which starts out an anonymous namespace.  Anonymous namespaces are to 
C++
 what the ttstatic/tt keyword is to C (at global scope).  It makes the
@@ -237,9 +243,9 @@
 
 pNext, we declare our pass itself:/p
 
-pre
+div class=doc_codepre
   bstruct/b Hello : bpublic/b a href=#FunctionPassFunctionPass/a 
{
-/prep
+/pre/divp
 
 pThis declares a ttHello/tt class that is a subclass of tta
 
href=http://llvm.org/doxygen/classllvm_1_1FunctionPass.html;FunctionPass/a/tt.
@@ -248,13 +254,13 @@
 href=#FunctionPassttFunctionPass/tt/a's operate a function at a
 time./p
 
-pre
+div class=doc_codepre
 bvirtual bool/b a href=#runOnFunctionrunOnFunction/a(Function 
amp;F) {
   std::cerr lt;lt; iHello: /i lt;lt; F.getName() lt;lt; \n;
   breturn false/b;
 }
   };  i// end of struct Hello/i
-/pre
+/pre/div
 
 pWe declare a a href=#runOnFunctionttrunOnFunction/tt/a method,
 which overloads an abstract virtual method inherited from a
@@ -262,10 +268,10 @@
 to do our thing, so we just print out our message with the name of each
 function./p
 
-pre
+div class=doc_codepre
   RegisterOptlt;Hellogt; X(ihello/i, iHello World Pass/i);
 }  i// end of anonymous namespace/i
-/pre
+/pre/div
 
 pLastly, we register our class ttHello/tt, giving it a command line
 argument tthello/tt, and a name ttHello World Pass/tt.  There are
@@ -275,7 +281,7 @@
 
 pAs a whole, the tt.cpp/tt file looks like:/p
 
-pre
+div class=doc_codepre
 b#include/b a 
href=http://llvm.org/doxygen/Pass_8h-source.html;llvm/Pass.h/a
 b#include/b a 
href=http://llvm.org/doxygen/Function_8h-source.html;llvm/Function.h/a
 
@@ -291,7 +297,7 @@
   
   RegisterOptlt;Hellogt; X(ihello/i, iHello World Pass/i);
 }
-/pre
+/pre/div
 
 pNow that it's all together, compile the file with a simple ttgmake/tt
 command in the local directory and you should get a new
@@ -320,12 +326,12 @@
 through our transformation like this (or course, any bytecode file will
 work):/p
 
-pre
+div class=doc_codepre
 $ opt -load ../../../Debug/lib/Hello.so -hello lt; hello.bc gt; /dev/null
 Hello: __main
 Hello: puts
 Hello: main
-/pre
+/pre/div
 
 pThe 'tt-load/tt' option specifies that 'ttopt/tt' should load your
 pass as a shared object, which makes 'tt-hello/tt' a valid command line
@@ -337,7 +343,7 @@
 pTo see what happened to the other string you registered, try running
 ttopt/tt with the tt--help/tt option:/p
 
-pre
+div 

[llvm-commits] CVS: llvm/docs/WritingAnLLVMPass.html

2006-01-06 Thread Robert L. Bocchino Jr.


Changes in directory llvm/docs:

WritingAnLLVMPass.html updated: 1.42 - 1.43
---
Log message:

Fixed a typo; = 1 was missing.


---
Diffs of the changes:  (+2 -2)

 WritingAnLLVMPass.html |4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)


Index: llvm/docs/WritingAnLLVMPass.html
diff -u llvm/docs/WritingAnLLVMPass.html:1.42 
llvm/docs/WritingAnLLVMPass.html:1.43
--- llvm/docs/WritingAnLLVMPass.html:1.42   Mon Nov 28 17:25:41 2005
+++ llvm/docs/WritingAnLLVMPass.htmlFri Jan  6 16:49:23 2006
@@ -177,7 +177,7 @@
 
 # Make the shared library become a loadable module so the tools can 
 # dlopen/dlsym on the resulting library.
-LOADABLE_MODULE
+LOADABLE_MODULE = 1
 
 # Include the makefile implementation stuff
 include $(LEVEL)/Makefile.common
@@ -1593,7 +1593,7 @@
 
   a href=mailto:[EMAIL PROTECTED]Chris Lattner/abr
   a href=http://llvm.cs.uiuc.edu;The LLVM Compiler Infrastructure/abr
-  Last modified: $Date: 2005/11/28 23:25:41 $
+  Last modified: $Date: 2006/01/06 22:49:23 $
 /address
 
 /body



___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits