Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions clang/include/clang/Driver/Options.td
Original file line number Diff line number Diff line change
Expand Up @@ -5559,8 +5559,10 @@ def finclude_default_header : Flag<["-"], "finclude-default-header">,
HelpText<"Include default header file for OpenCL">;
def fdeclare_opencl_builtins : Flag<["-"], "fdeclare-opencl-builtins">,
HelpText<"Add OpenCL builtin function declarations (experimental)">;
def fdeclare_spirv_builtins : Flag<["-"], "fdeclare-spirv-builtins">,
HelpText<"Add SPIR-V builtin function declarations (experimental)">;
def fdeclare_spirv_builtins
: Flag<["-"], "fdeclare-spirv-builtins">,
HelpText<"Add SPIR-V builtin function declarations (experimental)">,
MarshallingInfoFlag<LangOpts<"DeclareSPIRVBuiltins">>;

def fpreserve_vec3_type : Flag<["-"], "fpreserve-vec3-type">,
HelpText<"Preserve 3-component vector type">,
Expand Down
4 changes: 0 additions & 4 deletions clang/lib/Frontend/CompilerInvocation.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3502,8 +3502,6 @@ void CompilerInvocation::GenerateLangArgs(const LangOptions &Opts,
LangOptions::SignReturnAddressKeyKind::BKey)
GenerateArg(Args, OPT_msign_return_address_key_EQ, "b_key", SA);

if (Opts.DeclareSPIRVBuiltins)
GenerateArg(Args, OPT_fdeclare_spirv_builtins, SA);
}

bool CompilerInvocation::ParseLangArgs(LangOptions &Opts, ArgList &Args,
Expand Down Expand Up @@ -3594,8 +3592,6 @@ bool CompilerInvocation::ParseLangArgs(LangOptions &Opts, ArgList &Args,
}
}

Opts.DeclareSPIRVBuiltins = Args.hasArg(OPT_fdeclare_spirv_builtins);

// These need to be parsed now. They are used to set OpenCL defaults.
Opts.IncludeDefaultHeader = Args.hasArg(OPT_finclude_default_header);
Opts.DeclareOpenCLBuiltins = Args.hasArg(OPT_fdeclare_opencl_builtins);
Expand Down