TargetOptions.h revision 263508
1//===--- TargetOptions.h ----------------------------------------*- C++ -*-===// 2// 3// The LLVM Compiler Infrastructure 4// 5// This file is distributed under the University of Illinois Open Source 6// License. See LICENSE.TXT for details. 7// 8//===----------------------------------------------------------------------===// 9/// 10/// \file 11/// \brief Defines the clang::TargetOptions class. 12/// 13//===----------------------------------------------------------------------===// 14 15#ifndef LLVM_CLANG_FRONTEND_TARGETOPTIONS_H 16#define LLVM_CLANG_FRONTEND_TARGETOPTIONS_H 17 18#include "clang/Basic/LLVM.h" 19#include "llvm/ADT/IntrusiveRefCntPtr.h" 20#include <string> 21#include <vector> 22 23namespace clang { 24 25/// \brief Options for controlling the target. 26class TargetOptions : public RefCountedBase<TargetOptions> { 27public: 28 /// If given, the name of the target triple to compile for. If not given the 29 /// target will be selected to match the host. 30 std::string Triple; 31 32 /// If given, the name of the target CPU to generate code for. 33 std::string CPU; 34 35 /// If given, the unit to use for floating point math. 36 std::string FPMath; 37 38 /// If given, the name of the target ABI to use. 39 std::string ABI; 40 41 /// If given, the name of the target C++ ABI to use. If not given, defaults 42 /// to "itanium". 43 std::string CXXABI; 44 45 /// If given, the version string of the linker in use. 46 std::string LinkerVersion; 47 48 /// \brief The list of target specific features to enable or disable, as written on the command line. 49 std::vector<std::string> FeaturesAsWritten; 50 51 /// The list of target specific features to enable or disable -- this should 52 /// be a list of strings starting with by '+' or '-'. 53 std::vector<std::string> Features; 54}; 55 56} // end namespace clang 57 58#endif 59