From b0bfe2e8f6de5d0da633d165daf9e9f8ac5b7e44 Mon Sep 17 00:00:00 2001 From: Jan Svoboda Date: Tue, 5 Jan 2021 17:00:46 +0100 Subject: [PATCH] Reapply multiple "[clang][cli]" patches This reverts 7ad666798f12 and 1876a2914fe0 that reverted: 741978d727a4 [clang][cli] Port CodeGen option flags to new option parsing system 383778e2171b [clang][cli] Port LangOpts option flags to new option parsing system aec2991d083a [clang][cli] Port LangOpts simple string based options to new option parsing system 95d3cc67caac [clang][cli] Port CodeGenOpts simple string flags to new option parsing system 27b7d646886d [clang][cli] Streamline MarshallingInfoFlag description 70410a264949 [clang][cli] Let denormalizer decide how to render the option based on the option class 63a24816f561 [clang][cli] Implement `getAllArgValues` marshalling Commit 741978d727a4 accidentally changed the `Group` attribute of `g[no_]column_info` options from `g_flags_Group` to `g_Group`, which changed the debug info options passed to cc1 by the driver. Similar change was also present in 383778e2171b, which accidentally added `Group` to `f[no_]const_strings` and `f[no_]signed_wchar`. This patch corrects all three accidental changes by replacing `Bool{G,F}Option` with `BoolCC1Option`. --- include/llvm/Option/OptParser.td | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) diff --git a/include/llvm/Option/OptParser.td b/include/llvm/Option/OptParser.td index c1233297a7e..e1139d6c02f 100644 --- a/include/llvm/Option/OptParser.td +++ b/include/llvm/Option/OptParser.td @@ -167,12 +167,24 @@ class MarshallingInfoStringInt + : MarshallingInfo({})"> { + code Normalizer = "normalizeStringVector"; + code Denormalizer = "denormalizeStringVector"; +} + class MarshallingInfoFlag : MarshallingInfo { code Normalizer = "normalizeSimpleFlag"; code Denormalizer = "denormalizeSimpleFlag"; } +class MarshallingInfoNegativeFlag + : MarshallingInfo { + code Normalizer = "normalizeSimpleNegativeFlag"; + code Denormalizer = "denormalizeSimpleFlag"; +} + class MarshallingInfoBitfieldFlag : MarshallingInfoFlag { code Normalizer = "makeFlagToValueNormalizer("#value#")"; @@ -190,9 +202,6 @@ class MarshallingInfoBooleanFlag { code Normalizer = normalizer; } class Denormalizer { code Denormalizer = denormalizer; } @@ -202,9 +211,6 @@ class AutoNormalizeEnum { code Normalizer = "normalizeSimpleEnum"; code Denormalizer = "denormalizeSimpleEnum"; } -class AutoNormalizeEnumJoined : AutoNormalizeEnum { - code Denormalizer = "denormalizeSimpleEnumJoined"; -} class ValueMerger { code ValueMerger = merger; } class ValueExtractor { code ValueExtractor = extractor; }