2017-02-10 09:33:54 +08:00
|
|
|
//===- lib/MC/MCTargetOptions.cpp - MC Target Options ---------------------===//
|
2014-04-23 19:16:03 +08:00
|
|
|
//
|
2019-01-19 16:50:56 +08:00
|
|
|
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
|
|
|
|
// See https://llvm.org/LICENSE.txt for license information.
|
|
|
|
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
|
2014-04-23 19:16:03 +08:00
|
|
|
//
|
|
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
|
|
|
|
#include "llvm/MC/MCTargetOptions.h"
|
2017-06-06 19:49:48 +08:00
|
|
|
#include "llvm/ADT/StringRef.h"
|
2014-04-23 19:16:03 +08:00
|
|
|
|
2017-02-10 09:33:54 +08:00
|
|
|
using namespace llvm;
|
2014-04-23 19:16:03 +08:00
|
|
|
|
2014-05-15 09:08:00 +08:00
|
|
|
MCTargetOptions::MCTargetOptions()
|
Remove ASan asm instrumentation.
Summary: It is incomplete and has no users AFAIK.
Reviewers: pcc, vitalybuka
Subscribers: srhines, kubamracek, mgorny, krytarowski, eraman, hiraditya, jdoerfert, #sanitizers, llvm-commits, thakis
Tags: #sanitizers, #llvm
Differential Revision: https://reviews.llvm.org/D59154
llvm-svn: 355870
2019-03-12 05:50:10 +08:00
|
|
|
: MCRelaxAll(false), MCNoExecStack(false), MCFatalWarnings(false),
|
|
|
|
MCNoWarn(false), MCNoDeprecatedWarn(false), MCSaveTempLabels(false),
|
|
|
|
MCUseDwarfDirectory(false), MCIncrementalLinkerCompatible(false),
|
2020-01-01 16:15:28 +08:00
|
|
|
ShowMCEncoding(false), ShowMCInst(false), AsmVerbose(false),
|
2020-06-03 14:15:51 +08:00
|
|
|
PreserveAsmComments(true), Dwarf64(false) {}
|
2015-01-14 08:50:31 +08:00
|
|
|
|
|
|
|
StringRef MCTargetOptions::getABIName() const {
|
|
|
|
return ABIName;
|
|
|
|
}
|
[ms] [llvm-ml] Add a draft MASM parser
Summary:
Many directives are unavailable, and support for others may be limited.
This first draft has preliminary support for:
- conditional directives (including errors),
- data allocation (unsigned types up to 8 bytes, and ALIGN),
- equates/variables (numeric and text),
- and procedure directives (without parameters),
as well as COMMENT, ECHO, INCLUDE, INCLUDELIB, PUBLIC, and EXTERN. Text variables (aka text macros) are expanded in-place wherever the identifier occurs.
We deliberately ignore all ml.exe processor directives.
Prominent features not yet supported:
- structs
- macros (both procedures and functions)
- procedures (with specified parameters)
- substitution & expansion operators
Conditional directives are complicated by the fact that "ifdef rax" is a valid way to check if a file is being assembled for a 64-bit x86 processor; we add support for "ifdef <register>" in general, which requires adding a tryParseRegister method to all MCTargetAsmParsers. (Some targets require backtracking in the non-register case.)
Reviewers: rnk, thakis
Reviewed By: thakis
Subscribers: kerbowa, merge_guards_bot, wuzish, arsenm, dschuff, jyknight, dylanmckay, sdardis, nemanjai, jvesely, mgorny, sbc100, jgravelle-google, hiraditya, aheejin, kbarton, fedor.sergeev, asb, rbar, johnrusso, simoncook, sabuasal, niosHD, jrtc27, MaskRay, zzheng, edward-jones, atanasyan, rogfer01, MartinMosbeck, brucehoult, the_o, PkmX, jocewei, jsji, Jim, s.egerton, pzheng, sameer.abuasal, apazos, luismarques, llvm-commits
Tags: #llvm
Differential Revision: https://reviews.llvm.org/D72680
2020-02-17 01:29:51 +08:00
|
|
|
|
|
|
|
StringRef MCTargetOptions::getAssemblyLanguage() const {
|
|
|
|
return AssemblyLanguage;
|
|
|
|
}
|