| 110 | TargetLib &TargetLibAnalyzer::getTargetLib() { return *AnalyzedTargetLib; } |
| 111 | |
| 112 | std::vector<const llvm::Function *> |
| 113 | TargetLibAnalyzer::collectAnalyzableIRFunctions() const { |
| 114 | if (!SC) |
| 115 | return {}; |
| 116 | |
| 117 | std::vector<const llvm::Function *> Result; |
| 118 | bool All = AC.size() == 0 ? true : false; |
| 119 | for (const auto &F : SC->getLLVMModule()) { |
| 120 | if (F.isDeclaration()) |
| 121 | continue; |
| 122 | |
| 123 | if (!All && AC.find(F.getName().str()) == AC.end()) |
| 124 | continue; |
| 125 | |
| 126 | Result.push_back(&F); |
| 127 | } |
| 128 | return Result; |
| 129 | } |
| 130 | |
| 131 | void TargetLibAnalyzer::loadExternals(const std::string &ExternLibDir) { |
| 132 | if (!fs::is_directory(ExternLibDir)) |
nothing calls this directly
no test coverage detected