de8e2e6e421ca20c0813226d6ab00d3e750241a0
[oota-llvm.git] / include / llvm / CodeGen / Collectors.h
1 //===-- Collectors.h - Garbage collector registry -------------------------===//
2 //
3 //                     The LLVM Compiler Infrastructure
4 //
5 // This file was developed by Gordon Henriksen and is distributed under
6 // the University of Illinois Open Source License. See LICENSE.TXT for details.
7 //
8 //===----------------------------------------------------------------------===//
9 //
10 // This file declares the CollectorRegistry class, which is used to discover
11 // pluggable garbage collectors.
12 //
13 //===----------------------------------------------------------------------===//
14
15 #ifndef LLVM_CODEGEN_COLLECTORS_H
16 #define LLVM_CODEGEN_COLLECTORS_H
17
18 #include "llvm/Support/Registry.h"
19
20 namespace llvm {
21
22   class Collector;
23   
24   /// The collector registry uses all the defaults from Registry.
25   /// 
26   typedef Registry<Collector> CollectorRegistry;
27   
28   /// FIXME: Collector instances are not useful on their own. These no longer
29   ///        serve any purpose except to link in the plugins.
30   
31   /// Creates an ocaml-compatible garbage collector.
32   Collector *createOcamlCollector();
33   
34   /// Creates a shadow stack garbage collector. This collector requires no code
35   /// generator support.
36   Collector *createShadowStackCollector();
37 }
38
39 #endif