Benjamin Kramer | 9bcb922 | 2012-11-24 16:59:10 +0000 | [diff] [blame] | 1 | //===-- LTODisassembler.cpp - LTO Disassembler interface ------------------===// |
| 2 | // |
Chandler Carruth | 2946cd7 | 2019-01-19 08:50:56 +0000 | [diff] [blame] | 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 |
Benjamin Kramer | 9bcb922 | 2012-11-24 16:59:10 +0000 | [diff] [blame] | 6 | // |
| 7 | //===----------------------------------------------------------------------===// |
| 8 | // |
| 9 | // This function provides utility methods used by clients of libLTO that want |
| 10 | // to use the disassembler. |
| 11 | // |
| 12 | //===----------------------------------------------------------------------===// |
| 13 | |
| 14 | #include "llvm-c/lto.h" |
| 15 | #include "llvm/Support/TargetSelect.h" |
| 16 | |
| 17 | using namespace llvm; |
| 18 | |
| 19 | void lto_initialize_disassembler() { |
| 20 | // Initialize targets and assembly printers/parsers. |
| 21 | llvm::InitializeAllTargetInfos(); |
| 22 | llvm::InitializeAllTargetMCs(); |
| 23 | llvm::InitializeAllAsmParsers(); |
| 24 | llvm::InitializeAllDisassemblers(); |
| 25 | } |