[PATCH] D27513: Refactor clang's ParseHelper into Support (clang part)

2016-12-07 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a subscriber: cfe-commits. hans added a comment. I've commented on the llvm side. Adding cfe-commits as well since it affects clang. Repository: rL LLVM https://reviews.llvm.org/D27513 ___ cfe-commits mailing list cfe-commits@lists.ll

[PATCH] D27501: clang-format-vsix: add command to format document

2016-12-07 Thread Hans Wennborg via Phabricator via cfe-commits
hans added inline comments. Comment at: tools/clang-format-vs/ClangFormat/ClangFormat.vsct:76 + + Clang Format Document + I think File would be better than Document when referring to source code. But it seems a little annoying to need tw

[PATCH] D27501: clang-format-vsix: add command to format document

2016-12-07 Thread Hans Wennborg via Phabricator via cfe-commits
hans added inline comments. Comment at: tools/clang-format-vs/ClangFormat/ClangFormat.vsct:76 + + Clang Format Document + amaiorano wrote: > hans wrote: > > I think File would be better than Document when referring to source code. > > >

[PATCH] D27603: Propagate -fdiagnostics-color to LLD.

2016-12-09 Thread Hans Wennborg via Phabricator via cfe-commits
hans added inline comments. Comment at: lib/Driver/Tools.cpp:234 const ArgList &Args, ArgStringList &CmdArgs, const JobAction &JA) { const Driver &D = TC.getDriver(); ruiu wrote: > hans wrote: > > Yes,

[PATCH] D32369: [ms] Give -Wmicrosoft-enum-forward-reference a chance to fire in clang-cl, PR32736

2017-04-21 Thread Hans Wennborg via Phabricator via cfe-commits
hans accepted this revision. hans added a comment. This revision is now accepted and ready to land. lgtm https://reviews.llvm.org/D32369 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commi

[PATCH] D32371: Add comments to the diagnostic kinds in Diagnostic.td.

2017-04-21 Thread Hans Wennborg via Phabricator via cfe-commits
hans accepted this revision. hans added a comment. This revision is now accepted and ready to land. Highly useful I'd say! lgtm Comment at: include/clang/Basic/Diagnostic.td:113 +// Extensions are warnings about accepted language extensions that are +// default-off but enabled

[PATCH] D32435: clang-cl: Add support for /permissive-

2017-04-24 Thread Hans Wennborg via Phabricator via cfe-commits
hans accepted this revision. hans added a comment. This revision is now accepted and ready to land. lgtm https://reviews.llvm.org/D32435 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commi

[PATCH] D32879: Warn that the [] spelling of uuid(...) is deprecated.

2017-05-04 Thread Hans Wennborg via Phabricator via cfe-commits
hans accepted this revision. hans added a comment. This revision is now accepted and ready to land. lgtm https://reviews.llvm.org/D32879 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commi

[PATCH] D32914: Introduce Wzero-as-null-pointer-constant.

2017-05-05 Thread Hans Wennborg via Phabricator via cfe-commits
hans accepted this revision. hans added a comment. This revision is now accepted and ready to land. Nice. Some comments, but lgtm. Comment at: include/clang/Sema/Sema.h:3760 + /// \brief Warn when implicitly casting 0 to nullptr. + void diagnoseZeroToNullptrConversion(CastK

[PATCH] D33258: clang-cl: Fix path-based MSVC version detection

2017-05-16 Thread Hans Wennborg via Phabricator via cfe-commits
hans created this revision. The code wasn't taking the architecture-specific subdirectory into account. https://reviews.llvm.org/D33258 Files: lib/Driver/ToolChains/MSVC.cpp Index: lib/Driver/ToolChains/MSVC.cpp === --- lib/Dri

[PATCH] D33258: clang-cl: Fix path-based MSVC version detection

2017-05-16 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a subscriber: thakis. hans added a comment. Nico asked about tests. This whole thing landed (r297851) without tests, and I'm not sure it's worth the effort adding one for this :-/ https://reviews.llvm.org/D33258 ___ cfe-commits mailing l

[PATCH] D33258: clang-cl: Fix path-based MSVC version detection

2017-05-16 Thread Hans Wennborg via Phabricator via cfe-commits
hans updated this revision to Diff 99213. hans added a comment. Addressing comments. https://reviews.llvm.org/D33258 Files: lib/Driver/ToolChains/MSVC.cpp Index: lib/Driver/ToolChains/MSVC.cpp === --- lib/Driver/ToolChains/MSVC

[PATCH] D33258: clang-cl: Fix path-based MSVC version detection

2017-05-17 Thread Hans Wennborg via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL303267: clang-cl: Fix path-based MSVC version detection (authored by hans). Changed prior to commit: https://reviews.llvm.org/D33258?vs=99213&id=99310#toc Repository: rL LLVM https://reviews.llvm.or

[PATCH] D117407: [clang] Add include path for cppwinrt on Windows SDK 10.0.17134+

2022-01-18 Thread Hans Wennborg via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG9c195bae31c4: [clang] Add include path for cppwinrt on Windows SDK 10.0.17134+ (authored by saschanaz, committed by hans). Repository: rG LLVM Git

[PATCH] D117500: [clang] Mention MS on-demand TLS initialization in release notes

2022-01-18 Thread Hans Wennborg via Phabricator via cfe-commits
hans accepted this revision. hans added a comment. This revision is now accepted and ready to land. lgtm Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D117500/new/ https://reviews.llvm.org/D117500 ___ cfe

[PATCH] D98438: Clang: Allow selecting the hash algorithm for file checksums in debug info.

2022-01-21 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a comment. Do you think you'll have time to work on this? Otherwise I'd be happy to take it over. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D98438/new/ https://reviews.llvm.org/D98438 ___

[PATCH] D116395: [Clang] Emit warning for -x option without effects

2022-01-27 Thread Hans Wennborg via Phabricator via cfe-commits
hans added inline comments. Comment at: clang/lib/Driver/Driver.cpp:2416 } + if (Inputs.size() == InputsBeforeOptX && InputTypeArg != nullptr) +Diag(diag::warn_drv_ignored_option_x) << InputTypeArg->getValue(0); Could we end up here in clang-cl mode with

[PATCH] D118428: [clang-cl] Support the /JMC flag

2022-01-31 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a comment. This is great stuff, thanks! Comment at: clang/docs/ReleaseNotes.rst:155 +- Add support for MSVC-compatible ``/JMC``/``/JMC-`` flag in clang-cl, and + equivalent -cc1 flag ``-fjmc``. ``/JMC`` could only be used when ``/Zi`` or + ``/Z7`` is turned on. Wi

[PATCH] D118428: [clang-cl] Support the /JMC flag

2022-02-01 Thread Hans Wennborg via Phabricator via cfe-commits
hans added inline comments. Comment at: llvm/lib/CodeGen/CommandFlags.cpp:462 + static cl::opt EnableJMCInstrument( + "enable-jmc-instrument", + cl::desc("Instrument functions with a call to __CheckForDebuggerJustMyCode"), ychen wrote: > hans wrote: >

[PATCH] D118762: Remove -Wweak-template-vtables

2022-02-02 Thread Hans Wennborg via Phabricator via cfe-commits
hans created this revision. hans added a reviewer: dblaikie. hans requested review of this revision. Herald added a project: clang. as it was planned for removal in clang 15 and we're now past the branch point See https://github.com/llvm/llvm-project/issues/19107 Repository: rG LLVM G

[PATCH] D118428: [clang-cl] Support the /JMC flag

2022-02-02 Thread Hans Wennborg via Phabricator via cfe-commits
hans added inline comments. Comment at: llvm/lib/CodeGen/CommandFlags.cpp:462 + static cl::opt EnableJMCInstrument( + "enable-jmc-instrument", + cl::desc("Instrument functions with a call to __CheckForDebuggerJustMyCode"), ychen wrote: > hans wrote: >

[PATCH] D101439: [clang-cl] Add parsing support for a bunch of new flags

2021-04-28 Thread Hans Wennborg via Phabricator via cfe-commits
hans created this revision. hans added reviewers: thakis, rnk. Herald added a subscriber: dang. hans requested review of this revision. Herald added a project: clang. MSVC has added some new flags. Although they're not supported, this adds parsing support for them so clang-cl doesn't treat them a

[PATCH] D101439: [clang-cl] Add parsing support for a bunch of new flags

2021-04-28 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a comment. In D101439#2722540 , @thakis wrote: > Do we silently ignore those all now? Are any of them semantically important > enough that we should emit an "not implemented, ignoring" diag instead? No, this patch makes us parse them as oppos

[PATCH] D101457: [clang] remove dead code after 2a1332245fc

2021-04-28 Thread Hans Wennborg via Phabricator via cfe-commits
hans accepted this revision. hans added a comment. This revision is now accepted and ready to land. lgtm The real question is how did you find this? :) CHANGES SINCE LAST ACTION https://reviews.llvm.org/D101457/new/ https://reviews.llvm.org/D101457 __

[PATCH] D101439: [clang-cl] Add parsing support for a bunch of new flags

2021-05-03 Thread Hans Wennborg via Phabricator via cfe-commits
hans marked 2 inline comments as done. hans added inline comments. Comment at: clang/include/clang/Driver/Options.td:6117 def _SLASH_favor : CLJoined<"favor">; +def _SLASH_fsanitize_address_use_after_return : CLJoined<"fsanitize-address-use-after-return">; +def _SLASH_fno_sanit

[PATCH] D101439: [clang-cl] Add parsing support for a bunch of new flags

2021-05-03 Thread Hans Wennborg via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. hans marked 2 inline comments as done. Closed by commit rG876bf516e7d4: [clang-cl] Add parsing support for a bunch of new flags (authored by hans). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://

[PATCH] D101832: [clang] accept -fsanitize-ignorelist= in addition to -fsanitize-blacklist=

2021-05-04 Thread Hans Wennborg via Phabricator via cfe-commits
hans accepted this revision. hans added a comment. This revision is now accepted and ready to land. lgtm Comment at: clang/include/clang/Driver/Options.td:1524 + Alias, + HelpText<"Deprecated, use -fsanitize-coverage-ignorelist= instead">; def fsanitize_memory_track_origins_

[PATCH] D101805: [WebAssembly] Add codegen test for wasm_simd128.h

2021-05-05 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a comment. The test was failing in no-asserts builds, see output at https://ghostbin.com/paste/UMtJl I put "REQUIRES: asserts" on it in 4f4aa7b78df5544b0a1c07ee98475939c1175990 for now. Repository: rG LLVM Gith

[PATCH] D116313: [MSVC] Silence -Wnon-virtual-dtor on DIA APIs

2022-01-03 Thread Hans Wennborg via Phabricator via cfe-commits
hans added inline comments. Comment at: clang/lib/Driver/ToolChains/MSVC.cpp:54 +#endif #include "MSVCSetupApi.h" +#ifdef __clang__ Since it's in our repository, would it be possible to fix clang/lib/Driver/ToolChains/MSVCSetupApi.h to be warning free? If it's

[PATCH] D116313: [MSVC] Silence -Wnon-virtual-dtor on DIA APIs

2022-01-03 Thread Hans Wennborg via Phabricator via cfe-commits
hans accepted this revision. hans added a comment. This revision is now accepted and ready to land. lgtm Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D116313/new/ https://reviews.llvm.org/D116313 ___ cfe

[PATCH] D116313: [MSVC] Silence -Wnon-virtual-dtor on DIA APIs

2022-01-05 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a comment. In D116313#3218224 , @aganea wrote: > I was wondering, can we mandate `LLVM_ENABLE_WERROR=ON` for all bots at > least? (or maybe enable it through cmake, if ever there's a setting to detect > we're running as a bot) > Or just rever

[PATCH] D116511: [clang-cl] Support the /HOTPATCH flag

2022-01-07 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a comment. Cool! I'd suggesting adding a note to llvm/docs/ReleaseNotes.rst at the same time :-) Comment at: clang/include/clang/Basic/CodeGenOptions.def:142 +CODEGENOPT(HotPatch, 1, 0) ///< Supports the Microsoft /HOTPATCH flag and would +

[PATCH] D116835: Use sha256 for source file debug info checksums with MSVC compat >= 1930

2022-01-07 Thread Hans Wennborg via Phabricator via cfe-commits
hans created this revision. hans added reviewers: thakis, rnk, arlosi. Herald added subscribers: dexonsmith, hiraditya. hans requested review of this revision. Herald added projects: clang, LLVM. >From the VS2022 release notes, it sounds like newer MSVC versions are using >SHA256 for these checks

[PATCH] D116835: Use sha256 for source file debug info checksums with MSVC compat >= 1930

2022-01-07 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a comment. After sending this, I realized we should probably have a test to make sure it gets all the way into the .o and .pdb files correctly... And, maybe we should hook up the /ZH flag? (https://docs.microsoft.com/en-us/cpp/build/reference/zh?view=msvc-170&preserve-view=true stil

[PATCH] D98438: Clang: Allow selecting the hash algorithm for file checksums in debug info.

2022-01-10 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a comment. Sorry for not seeing this sooner. I think this looks great, just a few comments, and it also needs tests. Comment at: clang/include/clang/Basic/CodeGenOptions.def:303 +/// Set debug info source file hashing algorithm +ENUM_CODEGENOPT(DebugSrcHashAlgorithm

[PATCH] D116835: Use sha256 for source file debug info checksums with MSVC compat >= 1930

2022-01-10 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a comment. In D116835#3228296 , @arlosi wrote: > I submitted a change last year to hook up the /ZH option, but it was never > completed. https://reviews.llvm.org/D98438 I just put some comments on that. I'm happy to provide review if you thin

[PATCH] D116960: [ADT] Add an in-place version of toHex()

2022-01-10 Thread Hans Wennborg via Phabricator via cfe-commits
hans created this revision. hans added reviewers: thakis, arlosi, rnk. Herald added subscribers: dexonsmith, hiraditya. hans requested review of this revision. Herald added projects: clang, LLVM. Herald added a subscriber: cfe-commits. and use that to simplify MD5's hex string code which was previ

[PATCH] D116960: [ADT] Add an in-place version of toHex()

2022-01-10 Thread Hans Wennborg via Phabricator via cfe-commits
hans updated this revision to Diff 398699. hans added a comment. Trying to upload the right diff this time. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D116960/new/ https://reviews.llvm.org/D116960 Files: clang/lib/CodeGen/CGDebugInfo.cpp llvm/include/llvm/ADT/StringExtras.h llv

[PATCH] D116960: [ADT] Add an in-place version of toHex()

2022-01-10 Thread Hans Wennborg via Phabricator via cfe-commits
hans updated this revision to Diff 398704. hans added a comment. (avoid toStringRef -> arrayRefFromStringRef by reshuffling the toHex overloads) CHANGES SINCE LAST ACTION https://reviews.llvm.org/D116960/new/ https://reviews.llvm.org/D116960 Files: clang/lib/CodeGen/CGDebugInfo.cpp llvm/

[PATCH] D116960: [ADT] Add an in-place version of toHex()

2022-01-11 Thread Hans Wennborg via Phabricator via cfe-commits
hans marked 2 inline comments as done. hans added a comment. In D116960#3232461 , @dexonsmith wrote: > Mostly LGTM, just a couple of comments on the drive-by changes to > `hexdigit()` (I might split that (and the new call in toHex()) into a > separate

[PATCH] D116960: [ADT] Add an in-place version of toHex()

2022-01-11 Thread Hans Wennborg via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. hans marked 2 inline comments as done. Closed by commit rG83797c03d2ee: [ADT] Use a lookup table in hexdigit() and call that from toHex() (authored by hans). Changed p

[PATCH] D116511: [clang-cl] Support the /HOTPATCH flag

2022-01-12 Thread Hans Wennborg via Phabricator via cfe-commits
hans accepted this revision. hans added a comment. This revision is now accepted and ready to land. lgtm with comments Comment at: clang/test/CodeGenCXX/debug-info-hotpatch-arm.cpp:13 +// RUN: llvm-pdbutil dump -symbols %t.obj | FileCheck %s --check-prefix=HOTPATCH +// ERR-HOT

[PATCH] D116511: [clang-cl] Support the /HOTPATCH flag

2022-01-13 Thread Hans Wennborg via Phabricator via cfe-commits
hans added inline comments. Comment at: clang/test/CodeGenCXX/debug-info-hotpatch-arm.cpp:13 +// RUN: llvm-pdbutil dump -symbols %t.obj | FileCheck %s --check-prefix=HOTPATCH +// ERR-HOTPATCH: error: unsupported option '/hotpatch' for target +// HOTPATCH: S_COMPILE3 [size = [[#]

[PATCH] D116861: [UBSan] Fix incorrect alignment reported when global new returns an offset pointer

2022-01-13 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a reviewer: sepavloff. hans added a comment. I'm not familiar enough with the code to review it (though it sounds right to me). Looks like it was written by Serge originally. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D116861/new/ htt

[PATCH] D115456: [MS] Implement on-demand TLS initialization for Microsoft CXX ABI

2022-01-17 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a comment. Looks great, thanks! Maurice, do you want to add a note about this to docs/ReleaseNotes.rst? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D115456/new/ https://reviews.llvm.org/D115456

[PATCH] D117407: [clang] Add include path for cppwinrt on Windows SDK 10.0.17134+

2022-01-17 Thread Hans Wennborg via Phabricator via cfe-commits
hans accepted this revision. hans added a comment. This revision is now accepted and ready to land. lgtm, thanks! Do you have commit access, or would you like me to commit it for you? In D117407#3246794 , @saschanaz wrote: > That same check decorate_pro

[PATCH] D115252: Add note about inlining dllimport functions to the attribute docs

2021-12-07 Thread Hans Wennborg via Phabricator via cfe-commits
hans created this revision. hans added a reviewer: rnk. Herald added a reviewer: aaron.ballman. hans requested review of this revision. Herald added a project: clang. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D115252 Files: clang/include/clang/Basic/AttrDocs.td Index: cl

[PATCH] D115252: Add note about inlining dllimport functions to the attribute docs

2021-12-08 Thread Hans Wennborg via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG0a54c325beff: Add note about inlining dllimport functions to the attribute docs (authored by hans). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D115252/new/

[PATCH] D112081: Define __STDC_NO_THREADS__ when targeting windows-msvc (PR48704)

2021-12-16 Thread Hans Wennborg via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGbbc690c57213: Define __STDC_NO_THREADS__ when targeting windows-msvc (PR48704) (authored by hans). Changed prior to commit: https://reviews.llvm.org/D112081?vs=380704&id=394877#toc Repository: rG LLV

[PATCH] D112081: Define __STDC_NO_THREADS__ when targeting windows-msvc (PR48704)

2021-12-16 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a comment. Thanks for the reminder! Landed now. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112081/new/ https://reviews.llvm.org/D112081 ___ cfe-commits mailing list cfe-commits@lists.llvm.o

[PATCH] D94355: [Passes] Add relative lookup table converter pass

2021-03-16 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a comment. Sorry for being unresponsive for a while, I got distracted by various bugs. I skimmed this and it's looking great. Just added a few nit picks. Comment at: llvm/lib/Transforms/Utils/RelLookupTableConverter.cpp:32 + // If lookup table has more than one use

[PATCH] D100480: Add flag for showing skipped headers in -H / --show-includes output

2021-04-14 Thread Hans Wennborg via Phabricator via cfe-commits
hans created this revision. hans added reviewers: thakis, rnk. Herald added subscribers: jansvoboda11, dang. hans requested review of this revision. Herald added a project: clang. Consider the following set of files: a.cc: #include "a.h" a.h: #ifndef A_H #define A_H #include "b.

[PATCH] D100480: Add flag for showing skipped headers in -H / --show-includes output

2021-04-14 Thread Hans Wennborg via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rGf29dcbdde10c: Add flag for showing skipped headers in -H / --show-includes output (authored by hans). Repository: rG LLVM Github Monorepo CHANGES

[PATCH] D100759: Rename -show-skipped-includes to -fshow-skipped-includes and make it a driver option

2021-04-19 Thread Hans Wennborg via Phabricator via cfe-commits
hans created this revision. hans added a reviewer: thakis. Herald added subscribers: jansvoboda11, dang. hans requested review of this revision. Herald added a project: clang. This is a user-facing option, so it doesn't make sense for it to be cc1 only. Follow-up to D100420

[PATCH] D100759: Rename -show-skipped-includes to -fshow-skipped-includes and make it a driver option

2021-04-19 Thread Hans Wennborg via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rGbb36dc8dcf1c: Rename -show-skipped-includes to -fshow-skipped-includes and make it a driver… (authored by hans). Repository: rG LLVM Github Monore

[PATCH] D90976: [NFC] Fixed an issue where diagnostics printed expressions in a roundabout way

2021-01-11 Thread Hans Wennborg via Phabricator via cfe-commits
hans added inline comments. Comment at: clang/lib/AST/TemplateBase.cpp:485 case TemplateArgument::Expression: { -// This shouldn't actually ever happen, so it's okay that we're -// regurgitating an expression here. This code looks like a very special c

[PATCH] D82862: [ThinLTO] Always parse module level inline asm with At&t dialect

2021-01-14 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a comment. In D82862#2498242 , @uweigand wrote: > Hi @hans , we're having some issues with using the AssemblerDialect mechanism > to support both the GNU assembler and the IBM HLASM assembler in the SystemZ > back-end. See also the discuss

[PATCH] D82862: [ThinLTO] Always parse module level inline asm with At&t dialect

2021-01-15 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a subscriber: rnk. hans added a comment. > In D82862#2498785 , @hans wrote: > >> The motivation for my change was really just to make ThinLTO compiles work >> the same as non-ThinLTO ones. >> >> Maybe the fact that -x86-asm-syntax=intel doesn't

[PATCH] D111232: [clang] Don't mark _ReadBarrier(), _ReadWriteBarrier(), _WriteBarrier() deprecated

2021-10-06 Thread Hans Wennborg via Phabricator via cfe-commits
hans accepted this revision. hans added a comment. This revision is now accepted and ready to land. Sounds very reasonable to me. lgtm CHANGES SINCE LAST ACTION https://reviews.llvm.org/D111232/new/ https://reviews.llvm.org/D111232 ___ cfe-commits

[PATCH] D111273: [clang-format-diff] Fix missing formatting for zero length git diff lines

2021-10-07 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a comment. Are there no tests for clang-format-diff.py? That seems unfortunate. Will this handle more nested cases, for example if the first line here is deleted, will we fix the indent of both "if (b)" and "c"? if (a) if (b) c; I worry that this might be a tricky proble

[PATCH] D111250: [clang] Set max allowed alignment to 2^32

2021-10-07 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a comment. Is there any codegen test we could update to check that a high alignment value makes it all the way through to the IR? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D111250/new/ https://reviews.llvm.org/D111250 __

[PATCH] D111273: [clang-format-diff] Fix missing formatting for zero length git diff lines

2021-10-08 Thread Hans Wennborg via Phabricator via cfe-commits
hans accepted this revision. hans added a comment. This revision is now accepted and ready to land. lgtm If you want to look into it, I think having some kind of test for this script would be useful. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D1

[PATCH] D111440: [MS compat] Handle #pragma fenv_access like #pragma STDC FENV_ACCESS (PR50694)

2021-10-08 Thread Hans Wennborg via Phabricator via cfe-commits
hans created this revision. hans added reviewers: thakis, rsmith. Herald added a subscriber: dexonsmith. hans requested review of this revision. Herald added a project: clang. This adds support for the MSVC spelling of the pragma in -fms-extensions mode. Repository: rG LLVM Github Monorepo ht

[PATCH] D111440: [MS compat] Handle #pragma fenv_access like #pragma STDC FENV_ACCESS (PR50694)

2021-10-11 Thread Hans Wennborg via Phabricator via cfe-commits
hans marked an inline comment as done. hans added inline comments. Comment at: clang/lib/Parse/ParsePragma.cpp:280 +if (Tok.isNot(tok::l_paren)) { + PP.Diag(Tok.getLocation(), diag::warn_pragma_ms_fenv_access); + return; thakis wrote: > Is it import

[PATCH] D111440: [MS compat] Handle #pragma fenv_access like #pragma STDC FENV_ACCESS (PR50694)

2021-10-11 Thread Hans Wennborg via Phabricator via cfe-commits
hans updated this revision to Diff 378660. hans added a comment. Slightly better diags, try to appease clang-format. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D111440/new/ https://reviews.llvm.org/D111440 Files: clang/include/clang/Basic/DiagnosticParseKinds.td clang/include/cla

[PATCH] D111440: [MS compat] Handle #pragma fenv_access like #pragma STDC FENV_ACCESS (PR50694)

2021-10-11 Thread Hans Wennborg via Phabricator via cfe-commits
hans added inline comments. Comment at: clang/lib/Parse/ParsePragma.cpp:280 +if (Tok.isNot(tok::l_paren)) { + PP.Diag(Tok.getLocation(), diag::warn_pragma_ms_fenv_access); + return; thakis wrote: > hans wrote: > > thakis wrote: > > > Is it important

[PATCH] D111440: [MS compat] Handle #pragma fenv_access like #pragma STDC FENV_ACCESS (PR50694)

2021-10-11 Thread Hans Wennborg via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG774388241e25: [MS compat] Handle #pragma fenv_access like #pragma STDC FENV_ACCESS (PR50694) (authored by hans). Repository: rG LLVM Github Monore

[PATCH] D111570: [clang/CFG] Don't explicitly add AttributedStmtClass to AlwaysAddList

2021-10-12 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a comment. I guess I don't have enough context here. Why is AttributedStmtClass special here? Is it because it's a statement and the others are expressions, and so wouldn't go through CFGBlock::addStmt()? CHANGES SINCE LAST ACTION https://reviews.llvm.org/D111570/new/ https://rev

[PATCH] D111568: [clang] Omit most AttributedStatements from the CFG

2021-10-12 Thread Hans Wennborg via Phabricator via cfe-commits
hans added inline comments. Comment at: clang/lib/Analysis/CFG.cpp:545 CFGBlock *VisitAddrLabelExpr(AddrLabelExpr *A, AddStmtChoice asc); + CFGBlock *VisitAttributedStmt(AttributedStmt *C, AddStmtChoice asc); CFGBlock *VisitBinaryOperator(BinaryOperator *B, AddStmtChoice a

[PATCH] D111570: [clang/CFG] Don't explicitly add AttributedStmtClass to AlwaysAddList

2021-10-12 Thread Hans Wennborg via Phabricator via cfe-commits
hans accepted this revision. hans added a comment. This revision is now accepted and ready to land. Sounds good to me :) CHANGES SINCE LAST ACTION https://reviews.llvm.org/D111570/new/ https://reviews.llvm.org/D111570 ___ cfe-commits mailing list c

[PATCH] D111568: [clang] Omit most AttributedStatements from the CFG

2021-10-12 Thread Hans Wennborg via Phabricator via cfe-commits
hans accepted this revision. hans added inline comments. This revision is now accepted and ready to land. Comment at: clang/lib/Analysis/CFG.cpp:2407 + return hasSpecificAttr(A->getAttrs()) && + isa(A->getSubStmt()); +} thakis wrote: > hans wrote: > > Ca

[PATCH] D112081: Define __STDC_NO_THREADS__ when targeting windows-msvc (PR48704)

2021-10-19 Thread Hans Wennborg via Phabricator via cfe-commits
hans created this revision. hans added reviewers: aaron.ballman, rnk. hans requested review of this revision. Herald added a project: clang. MSVC's libc doesn't provide thread.h, so we should set the macro to indicate that. We could just set it in C mode, but I noticed that Darwin sets it uncon

[PATCH] D112081: Define __STDC_NO_THREADS__ when targeting windows-msvc (PR48704)

2021-10-19 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a comment. In D112081#3073067 , @aaron.ballman wrote: > Thanks for this! Should we similarly handle `__STDC_NO_ATOMICS__`, > `__STDC_NO_COMPLEX__`, et al at the same time? I'll look into those, thanks. > Also, how should we handle `__STDC_V

[PATCH] D112190: [clang] Don't clear AST if we have consumers running after the main action

2021-10-21 Thread Hans Wennborg via Phabricator via cfe-commits
hans accepted this revision. hans added a comment. lgtm Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112190/new/ https://reviews.llvm.org/D112190 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D107589: [CMake] Support setting default fused FP contract via CMake

2021-09-01 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a comment. I just got back from vacation, so am probably missing some of the discussion elsewhere, but I'm a bit skeptical of this patch. It seems it would be confusing for users if clang generates code with different floating-point behaviour depending on how it was built. Reposito

[PATCH] D109105: [clang-cl] Emit nicer warning on unknown /arch: arguments

2021-09-02 Thread Hans Wennborg via Phabricator via cfe-commits
hans accepted this revision. hans added a comment. This revision is now accepted and ready to land. lgtm, nice! Comment at: llvm/include/llvm/ADT/StringMap.h:301 + /// is inserted . + template void insert(InputIt First, InputIt Last) { +for (InputIt It = First; It != Las

[PATCH] D109085: clang/win: Add __readfsdword to intrin.h

2021-09-02 Thread Hans Wennborg via Phabricator via cfe-commits
hans accepted this revision. hans added a comment. This revision is now accepted and ready to land. lgtm CHANGES SINCE LAST ACTION https://reviews.llvm.org/D109085/new/ https://reviews.llvm.org/D109085 ___ cfe-commits mailing list cfe-commits@lists

[PATCH] D108003: [Clang] Extend -Wbool-operation to warn about bitwise and of bools with side effects

2021-09-06 Thread Hans Wennborg via Phabricator via cfe-commits
hans added inline comments. Comment at: clang/include/clang/Basic/DiagnosticSemaKinds.td:7428-7430 +def warn_bitwise_and_bool : Warning< + "bitwise and of boolean expressions; did you mean logical and?">, + InGroup; Quuxplusone wrote: > xbolva00 wrote: > > Quux

[PATCH] D106789: [clang][Driver] Expose driver mode detection logic

2021-09-07 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a comment. Somehow this seems to have broken the `--driver-mode=` flag when passed to clang-cl. The flag is supposed to override the mode inferred from the filename, but it's not working anymore. For example: Before: $ bin/clang-cl --driver-mode=gcc -target x86_64 -c /tmp/a.c -###

[PATCH] D109361: [clang][Driver] Pick the last --driver-mode in case of multiple ones

2021-09-07 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a comment. Thanks! I tried this locally and it fixes the issue I mentioned on D109361 Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D109361/new/ https://reviews.llvm.org/D109361 ___

[PATCH] D109361: [clang][Driver] Pick the last --driver-mode in case of multiple ones

2021-09-10 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a comment. In D109361#2986687 , @hans wrote: > Thanks! I tried this locally and it fixes the issue I mentioned on D109361 > Corection: it fixes the issue that that I mentioned on D106789

[PATCH] D109828: [clang-cl] Add a /diasdkdir flag and make /winsysroot imply it

2021-09-15 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a comment. The /winsysroot part makes sense to me, but what's the case for the new /diasdkdir flag? Comment at: clang/lib/Driver/ToolChains/MSVC.cpp:66 +static const char *llvmArchToLegacyVCArch(llvm::Triple::ArchType Arch); + Maybe move the arch

<    6   7   8   9   10   11