[SLP] Add cost model for `llvm.powi.*` intrinsics (REAPPLIED)
[llvm-project.git] / lld / MachO / LTO.h
blobd64016fb588c2cab8f35d93ff1b8cbd517e3f44d
1 //===- LTO.h ----------------------------------------------------*- C++ -*-===//
2 //
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6 //
7 //===----------------------------------------------------------------------===//
9 #ifndef LLD_MACHO_LTO_H
10 #define LLD_MACHO_LTO_H
12 #include "llvm/ADT/SmallString.h"
13 #include "llvm/Support/MemoryBuffer.h"
14 #include <memory>
15 #include <vector>
17 namespace llvm {
18 namespace lto {
19 class LTO;
20 } // namespace lto
21 } // namespace llvm
23 namespace lld {
24 namespace macho {
26 class BitcodeFile;
27 class ObjFile;
29 class BitcodeCompiler {
30 public:
31 BitcodeCompiler();
33 void add(BitcodeFile &f);
34 std::vector<ObjFile *> compile();
36 private:
37 std::unique_ptr<llvm::lto::LTO> ltoObj;
38 std::vector<llvm::SmallString<0>> buf;
39 std::vector<std::unique_ptr<llvm::MemoryBuffer>> files;
42 } // namespace macho
43 } // namespace lld
45 #endif