diff options
author | Puyan Lotfi <puyan@puyan.org> | 2019-08-22 23:29:22 +0000 |
---|---|---|
committer | Puyan Lotfi <puyan@puyan.org> | 2019-08-22 23:29:22 +0000 |
commit | d24184591fb7223fe6fea724be901ee501bf1cc3 (patch) | |
tree | 87ae017316348bb0afa4d4ebd845b001dd922b6b /clang/lib/Frontend/CompilerInvocation.cpp | |
parent | d6c1c7bfb68bc4158879e64a24115042c814c07a (diff) | |
download | llvm-d24184591fb7223fe6fea724be901ee501bf1cc3.zip llvm-d24184591fb7223fe6fea724be901ee501bf1cc3.tar.gz llvm-d24184591fb7223fe6fea724be901ee501bf1cc3.tar.bz2 |
[clang][ifs] New interface stubs format (llvm triple based).
After posting llvm-ifs on phabricator, I made some progress in hardening up how
I think the format for Interface Stubs should look. There are a number of
things I think the TBE format was missing (no endianness, no info about the
Object Format because it assumes ELF), so I have added those and broken off
from being as similar to the TBE schema. In a subsequent commit I can drop the
other formats.
An example of how The format will look is as follows:
--- !experimental-ifs-v1
IfsVersion: 1.0
Triple: x86_64-unknown-linux-gnu
ObjectFileFormat: ELF
Symbols:
_Z9nothiddenv: { Type: Func }
_Z10cmdVisiblev: { Type: Func }
...
The format is still marked experimental.
Differential Revision: https://reviews.llvm.org/D66446
llvm-svn: 369715
Diffstat (limited to 'clang/lib/Frontend/CompilerInvocation.cpp')
-rw-r--r-- | clang/lib/Frontend/CompilerInvocation.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/clang/lib/Frontend/CompilerInvocation.cpp b/clang/lib/Frontend/CompilerInvocation.cpp index 66684e5..c0539cd 100644 --- a/clang/lib/Frontend/CompilerInvocation.cpp +++ b/clang/lib/Frontend/CompilerInvocation.cpp @@ -1737,11 +1737,14 @@ static InputKind ParseFrontendArgs(FrontendOptions &Opts, ArgList &Args, frontend::GenerateInterfaceYAMLExpV1) .Case("experimental-tapi-elf-v1", frontend::GenerateInterfaceTBEExpV1) + .Case("experimental-ifs-v1", + frontend::GenerateInterfaceIfsExpV1) .Default(llvm::None); if (!ProgramAction) Diags.Report(diag::err_drv_invalid_value) << "Must specify a valid interface stub format type using " << "-interface-stub-version=<experimental-tapi-elf-v1 | " + "experimental-ifs-v1 | " "experimental-yaml-elf-v1>"; Opts.ProgramAction = *ProgramAction; break; @@ -3185,6 +3188,7 @@ static bool isStrictlyPreprocessorAction(frontend::ActionKind Action) { case frontend::GeneratePCH: case frontend::GenerateInterfaceYAMLExpV1: case frontend::GenerateInterfaceTBEExpV1: + case frontend::GenerateInterfaceIfsExpV1: case frontend::ParseSyntaxOnly: case frontend::ModuleFileInfo: case frontend::VerifyPCH: |