1//===----------------------------------------------------------------------===//
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//===----------------------------------------------------------------------===//
8
9#ifndef LLVM_LIB_IR_IROPTIONS_H
10#define LLVM_LIB_IR_IROPTIONS_H
11
12#include "llvm/Config/llvm-config.h"
13#include "llvm/IR/LLVMContext.h"
14
15namespace llvm {
16#ifdef LLVM_ENABLE_PROFCHECK
17constexpr bool ElideAllZeroBranchWeightsDefault = false;
18#else
19constexpr bool ElideAllZeroBranchWeightsDefault = true;
20#endif
21} // namespace llvm
22
23#define OPTIONS_STRUCT_DECL
24#include "IROptions.inc"
25
26namespace llvm {
27inline const IROptions &getIROptions(const LLVMContext &C) {
28 return C.getLibraryOptions().get<IROptions>();
29}
30} // namespace llvm
31
32#endif // LLVM_LIB_IR_IROPTIONS_H
33