The easiest way is to "cheat" and see how existing code does it. 
Take, dead store elimination, for example:
In DeadStoreElimination.cpp, there is
virtual void getAnalysisUsage(AnalysisUsage &AU) const {
AU.setPreservesCFG();
AU.addRequired<DominatorTree>();
AU.addRequired<AliasAnalysis>();
AU.addRequired<MemoryDependenceAnalysis>();
AU.addPreserved<AliasAnalysis>();
AU.addPreserved<DominatorTree>();
AU.addPreserved<MemoryDependenceAnalysis>();
}
and
INITIALIZE_PASS_BEGIN(DSE, "dse", "Dead Store Elimination", false, false)
INITIALIZE_PASS_DEPENDENCY(DominatorTree)
INITIALIZE_PASS_DEPENDENCY(MemoryDependenceAnalysis)
INITIALIZE_AG_DEPENDENCY(AliasAnalysis)
INITIALIZE_PASS_END(DSE, "dse", "Dead Store Elimination", false, false)
The macros will generate a function called "initializeDSEPass".
Now, in the same file, in the constructor, there is a call to it:
DSE() : FunctionPass(ID), AA(0), MD(0), DT(0) {
initializeDSEPass(*PassRegistry::getPassRegistry());
}
Now you can grep the sources to see if the "initializeDSEPass" is in any header. In my source tree, it's in:
include/llvm/InitializePasses.h
lib/Transforms/Scalar/DeadStoreElimination.cpp
lib/Transforms/Scalar/Scalar.cpp
In InitializePasses.h there is a namespace "llvm" with all the initialization functions listed in it. For a particular pass, the other occurrences may differ slightly, but this is the core of what you need.
You don't really need to use RegisterPass. I only found two places that use it and they both are in the code generation.
-Krzysztof