diff options
author | Eugene Zelenko <eugene.zelenko@gmail.com> | 2017-02-27 22:45:06 +0000 |
---|---|---|
committer | Eugene Zelenko <eugene.zelenko@gmail.com> | 2017-02-27 22:45:06 +0000 |
commit | fa912a7151aa59d71bb03cf1a60fd8dff650c482 (patch) | |
tree | e5f5d0463fd35464389de9ead942346d1c635c99 /llvm/lib/CodeGen/BuiltinGCs.cpp | |
parent | 1f4e26fc58ccdfb38858545fd0596f366ade1925 (diff) | |
download | bcm5719-llvm-fa912a7151aa59d71bb03cf1a60fd8dff650c482.tar.gz bcm5719-llvm-fa912a7151aa59d71bb03cf1a60fd8dff650c482.zip |
[CodeGen] Fix some Clang-tidy modernize and Include What You Use warnings; other minor fixes (NFC).
llvm-svn: 296404
Diffstat (limited to 'llvm/lib/CodeGen/BuiltinGCs.cpp')
-rw-r--r-- | llvm/lib/CodeGen/BuiltinGCs.cpp | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/llvm/lib/CodeGen/BuiltinGCs.cpp b/llvm/lib/CodeGen/BuiltinGCs.cpp index ff7c99de042..e4eab8c513d 100644 --- a/llvm/lib/CodeGen/BuiltinGCs.cpp +++ b/llvm/lib/CodeGen/BuiltinGCs.cpp @@ -1,4 +1,4 @@ -//===-- BuiltinGCs.cpp - Boilerplate for our built in GC types --*- C++ -*-===// +//===- BuiltinGCs.cpp - Boilerplate for our built in GC types -------------===// // // The LLVM Compiler Infrastructure // @@ -14,6 +14,8 @@ #include "llvm/CodeGen/GCs.h" #include "llvm/CodeGen/GCStrategy.h" +#include "llvm/IR/DerivedTypes.h" +#include "llvm/Support/Casting.h" using namespace llvm; @@ -77,6 +79,7 @@ public: UsesMetadata = false; CustomRoots = false; } + Optional<bool> isGCManagedPointer(const Type *Ty) const override { // Method is only valid on pointer typed values. const PointerType *PT = cast<PointerType>(Ty); @@ -110,6 +113,7 @@ public: UsesMetadata = false; CustomRoots = false; } + Optional<bool> isGCManagedPointer(const Type *Ty) const override { // Method is only valid on pointer typed values. const PointerType *PT = cast<PointerType>(Ty); @@ -117,7 +121,8 @@ public: return (1 == PT->getAddressSpace()); } }; -} + +} // end anonymous namespace // Register all the above so that they can be found at runtime. Note that // these static initializers are important since the registration list is |