diff options
author | Reid Spencer <rspencer@reidspencer.com> | 2006-06-07 20:00:19 +0000 |
---|---|---|
committer | Reid Spencer <rspencer@reidspencer.com> | 2006-06-07 20:00:19 +0000 |
commit | 6df60a9effe4d20a48cfd9d105c0ab3c5dc3e690 (patch) | |
tree | d5e3f627411a59fbe751d3208a73c0ab053baee8 /lib | |
parent | 19fd7ef7300616aa245e15e73b435c9bd0c83de3 (diff) | |
download | external_llvm-6df60a9effe4d20a48cfd9d105c0ab3c5dc3e690.zip external_llvm-6df60a9effe4d20a48cfd9d105c0ab3c5dc3e690.tar.gz external_llvm-6df60a9effe4d20a48cfd9d105c0ab3c5dc3e690.tar.bz2 |
For PR780:
Break the "IncludeFile" mechanism into its own header file and adjust other
files accordingly. Use this facility for the IntrinsicInst problem which
was the subject of PR800.
More to follow on this.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28709 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib')
-rw-r--r-- | lib/Analysis/AliasAnalysis.cpp | 1 | ||||
-rw-r--r-- | lib/Support/IncludeFile.cpp | 20 | ||||
-rw-r--r-- | lib/System/IncludeFile.cpp | 20 | ||||
-rw-r--r-- | lib/VMCore/IntrinsicInst.cpp | 4 | ||||
-rw-r--r-- | lib/VMCore/Pass.cpp | 3 |
5 files changed, 45 insertions, 3 deletions
diff --git a/lib/Analysis/AliasAnalysis.cpp b/lib/Analysis/AliasAnalysis.cpp index 6d5a375..2abcbde 100644 --- a/lib/Analysis/AliasAnalysis.cpp +++ b/lib/Analysis/AliasAnalysis.cpp @@ -25,6 +25,7 @@ //===----------------------------------------------------------------------===// #include "llvm/Analysis/AliasAnalysis.h" +#include "llvm/Pass.h" #include "llvm/BasicBlock.h" #include "llvm/Instructions.h" #include "llvm/Type.h" diff --git a/lib/Support/IncludeFile.cpp b/lib/Support/IncludeFile.cpp new file mode 100644 index 0000000..d472917 --- /dev/null +++ b/lib/Support/IncludeFile.cpp @@ -0,0 +1,20 @@ +//===- lib/Support/IncludeFile.cpp - Ensure Linking Of Implementation -----===// +// +// The LLVM Compiler Infrastructure +// +// This file was developed by Reid Spencer and is distributed under the +// University of Illinois Open Source License. See LICENSE.TXT for details. +// +//===----------------------------------------------------------------------===// +// +// This file implements the IncludeFile constructor. +// +//===----------------------------------------------------------------------===// + +#include "llvm/Support/IncludeFile.h" + +using namespace llvm; + +// This constructor is used to ensure linking of other modules. See the +// llvm/Support/IncludeFile.h header for details. +IncludeFile::IncludeFile(void*) {} diff --git a/lib/System/IncludeFile.cpp b/lib/System/IncludeFile.cpp new file mode 100644 index 0000000..d472917 --- /dev/null +++ b/lib/System/IncludeFile.cpp @@ -0,0 +1,20 @@ +//===- lib/Support/IncludeFile.cpp - Ensure Linking Of Implementation -----===// +// +// The LLVM Compiler Infrastructure +// +// This file was developed by Reid Spencer and is distributed under the +// University of Illinois Open Source License. See LICENSE.TXT for details. +// +//===----------------------------------------------------------------------===// +// +// This file implements the IncludeFile constructor. +// +//===----------------------------------------------------------------------===// + +#include "llvm/Support/IncludeFile.h" + +using namespace llvm; + +// This constructor is used to ensure linking of other modules. See the +// llvm/Support/IncludeFile.h header for details. +IncludeFile::IncludeFile(void*) {} diff --git a/lib/VMCore/IntrinsicInst.cpp b/lib/VMCore/IntrinsicInst.cpp index 2c2c5a9..b4395e1 100644 --- a/lib/VMCore/IntrinsicInst.cpp +++ b/lib/VMCore/IntrinsicInst.cpp @@ -71,3 +71,7 @@ std::string DbgStopPointInst::getDirectory() const { } //===----------------------------------------------------------------------===// +/// LinkIntrinsicInstStub -- This is a hack to make sure that programs that +/// #include IntrinsicInst.h also link this file. See Support/IncludeFile.h +/// for further details. +char llvm::LinkIntrinsicInstStub; diff --git a/lib/VMCore/Pass.cpp b/lib/VMCore/Pass.cpp index 9fed647..a7160f1 100644 --- a/lib/VMCore/Pass.cpp +++ b/lib/VMCore/Pass.cpp @@ -23,9 +23,6 @@ #include <set> using namespace llvm; -// IncludeFile - Stub function used to help linking out. -IncludeFile::IncludeFile(void*) {} - //===----------------------------------------------------------------------===// // AnalysisID Class Implementation // |