Page MenuHomePhabricator
Feed Advanced Search

Today

Mordante added a comment to D72231: [Sema] Adds the pointer-to-int-cast diagnostic.

There appear to a be semantic difference between GCC and clang with the current version of this patch which results in a lot of additional warnings in the Linux kernel: https://godbolt.org/z/eHFJd8

Warning about casting to an enum seems clearly correct and in scope for this warning. Warning about casting to _Bool seems clearly incorrect and should not be warned about at all.

Tue, Feb 18, 1:03 PM · Restricted Project

Sun, Feb 16

Mordante committed rGaf202119443b: [Sema] Fix pointer-to-int-cast for MSVC build bot (authored by Mordante).
[Sema] Fix pointer-to-int-cast for MSVC build bot
Sun, Feb 16, 10:11 AM
Mordante closed D74694: [Sema] Fix pointer-to-int-cast for MSVC build bot.
Sun, Feb 16, 10:11 AM · Restricted Project
Mordante added a comment to D74694: [Sema] Fix pointer-to-int-cast for MSVC build bot.

Thanks for the quick review!

Sun, Feb 16, 10:09 AM · Restricted Project
Mordante created D74694: [Sema] Fix pointer-to-int-cast for MSVC build bot.
Sun, Feb 16, 9:42 AM · Restricted Project
Mordante added a comment to D72231: [Sema] Adds the pointer-to-int-cast diagnostic.

This revision caused issue for the MSVC build bot. I created a followup patch D74694.

Sun, Feb 16, 9:42 AM · Restricted Project
Mordante planned changes to D71966: [Wdocumentation][RFC] Improve identifier's of \param.
Sun, Feb 16, 9:06 AM · Restricted Project
Mordante committed rG9658d895c81a: [Sema] Adds the pointer-to-int-cast diagnostic (authored by Mordante).
[Sema] Adds the pointer-to-int-cast diagnostic
Sun, Feb 16, 6:43 AM
Mordante closed D72231: [Sema] Adds the pointer-to-int-cast diagnostic.
Sun, Feb 16, 6:42 AM · Restricted Project
Mordante added a comment to D72231: [Sema] Adds the pointer-to-int-cast diagnostic.

Thanks for the review.

Sun, Feb 16, 6:42 AM · Restricted Project
Mordante closed D73834: Update for Clang 10 release notes.

Phab registered the commit, but didn't close this review.

Sun, Feb 16, 5:54 AM · Restricted Project

Tue, Feb 4

Mordante updated the diff for D72231: [Sema] Adds the pointer-to-int-cast diagnostic.
  • Enabled the warning by default
  • Added an Microsoft extension, the unit tests already expected this behaviour
Tue, Feb 4, 11:53 AM · Restricted Project
Mordante committed rG2d9954dd8244: Add -Wrange-loop-analysis changes to ReleaseNotes (authored by Mordante).
Add -Wrange-loop-analysis changes to ReleaseNotes
Tue, Feb 4, 11:26 AM

Sat, Feb 1

Mordante added a comment to D73434: [Sema] Remove a -Wrange warning from -Wall.

Created D73834 to cherry-pick the changes to the release branch and updates the release notes.

Sat, Feb 1, 10:09 AM · Restricted Project
Mordante created D73834: Update for Clang 10 release notes.
Sat, Feb 1, 10:09 AM · Restricted Project
Mordante committed rGc03349e40f21: [Sema] Remove a -Wrange warning from -Wall (authored by Mordante).
[Sema] Remove a -Wrange warning from -Wall
Sat, Feb 1, 9:51 AM
Mordante closed D73434: [Sema] Remove a -Wrange warning from -Wall.
Sat, Feb 1, 9:51 AM · Restricted Project

Sun, Jan 26

Mordante added a comment to D73007: [Sema] Avoid Wrange-loop-analysis false positives.

Created D73434.

Sun, Jan 26, 10:18 AM · Restricted Project
Mordante created D73434: [Sema] Remove a -Wrange warning from -Wall.
Sun, Jan 26, 10:17 AM · Restricted Project
Mordante added a comment to D71966: [Wdocumentation][RFC] Improve identifier's of \param.

So if I understand correctly:

  • getParamNameAsWritten will become getArgText
  • The getParamName will do the translation from the name in the documentation to the name in the current function declaration. If the parameter index is invalid the function will fail (with an assertion error) and not fallback to call getArgText.
Sun, Jan 26, 8:40 AM · Restricted Project
Mordante added a comment to D73007: [Sema] Avoid Wrange-loop-analysis false positives.

@aaronpuchert, @aaron.ballman I agree with the proposal, I'll work on a patch.

Sun, Jan 26, 7:55 AM · Restricted Project

Tue, Jan 21

Mordante added a comment to D73098: [clang-tidy] readability-identifier-naming disregards parameters restrictions on main like functions.

Would it make sense to also allow wmain with wchar_t? https://docs.microsoft.com/en-us/cpp/cpp/main-function-command-line-args?view=vs-2019

Tue, Jan 21, 12:23 PM · Restricted Project, Restricted Project
Mordante committed rG41fcd17250fa: [Sema] Avoid Wrange-loop-analysis false positives (authored by Mordante).
[Sema] Avoid Wrange-loop-analysis false positives
Tue, Jan 21, 12:14 PM
Mordante closed D73007: [Sema] Avoid Wrange-loop-analysis false positives.
Tue, Jan 21, 12:14 PM · Restricted Project
Mordante added inline comments to D73007: [Sema] Avoid Wrange-loop-analysis false positives.
Tue, Jan 21, 11:55 AM · Restricted Project
Mordante added a comment to D73007: [Sema] Avoid Wrange-loop-analysis false positives.

LGTM! Do you think this should also be pushed onto the release branch?

Tue, Jan 21, 11:46 AM · Restricted Project
Mordante added a comment to D73007: [Sema] Avoid Wrange-loop-analysis false positives.

Yes, but minimal fix is better for release branch, so @hans should merge it.

Handling your case probably needs more work and patches..

Tue, Jan 21, 11:46 AM · Restricted Project

Jan 19 2020

Mordante added a comment to D68912: Adds -Wrange-loop-analysis to -Wall.

I proposed D73007 as fix.

Jan 19 2020, 10:12 AM · Restricted Project
Mordante created D73007: [Sema] Avoid Wrange-loop-analysis false positives.
Jan 19 2020, 10:03 AM · Restricted Project

Jan 18 2020

Mordante added a comment to D68912: Adds -Wrange-loop-analysis to -Wall.

Thanks for your report. I think it's similar to https://bugs.llvm.org/show_bug.cgi?id=44556. I'll look for a fix.

Jan 18 2020, 12:06 PM · Restricted Project
Mordante added a comment to D71966: [Wdocumentation][RFC] Improve identifier's of \param.

Thanks for the review!

Jan 18 2020, 11:56 AM · Restricted Project

Jan 12 2020

Mordante closed D72560: Add -Wrange-loop-analysis changes to ReleaseNotes.

Committed as https://reviews.llvm.org/rGdc422e968e73790178e500f506e8fb7cfa1e62ea

Jan 12 2020, 11:06 AM · Restricted Project

Jan 11 2020

Mordante committed rGdc422e968e73: Add -Wrange-loop-analysis changes to ReleaseNotes (authored by Mordante).
Add -Wrange-loop-analysis changes to ReleaseNotes
Jan 11 2020, 11:03 AM
Mordante added a comment to D72560: Add -Wrange-loop-analysis changes to ReleaseNotes.

Thanks for the review!

Jan 11 2020, 11:03 AM · Restricted Project
Mordante created D72560: Add -Wrange-loop-analysis changes to ReleaseNotes.
Jan 11 2020, 10:10 AM · Restricted Project
Mordante added inline comments to D72052: [UserManual] Update the C++ standard support.
Jan 11 2020, 8:46 AM · Restricted Project
Mordante added a comment to D72553: [clang-tidy] Add performance-prefer-preincrement check.
  • 99% sure I have all incriments renamed now
Jan 11 2020, 8:46 AM · Restricted Project, Restricted Project
Mordante added a comment to D72553: [clang-tidy] Add performance-prefer-preincrement check.

I only have some naming nits

  • incriment -> increment
  • decriment -> decrement
Jan 11 2020, 7:24 AM · Restricted Project, Restricted Project
Mordante added a comment to D72052: [UserManual] Update the C++ standard support.

Friendly ping, it would be nice to get this in the next release.

Jan 11 2020, 7:06 AM · Restricted Project
Mordante added a comment to D72378: [clang-tidy] Add `bugprone-reserved-identifier`.

Adding Depends on D72284 would add the patches to the stack.
I like the patch!

Jan 11 2020, 6:58 AM · Restricted Project, Restricted Project
Mordante committed rG9c74fb402e1b: [Sema] Improve -Wrange-loop-analysis warnings. (authored by Mordante).
[Sema] Improve -Wrange-loop-analysis warnings.
Jan 11 2020, 6:38 AM
Mordante closed D72212: [Sema] Improve -Wrange-loop-analysis warnings.
Jan 11 2020, 6:38 AM · Restricted Project
Mordante added inline comments to D72212: [Sema] Improve -Wrange-loop-analysis warnings.
Jan 11 2020, 6:38 AM · Restricted Project

Jan 7 2020

Mordante planned changes to D72231: [Sema] Adds the pointer-to-int-cast diagnostic.

While looking at the test failures I noticed the tests pointer_to_integral_type_conv in clang/test/Sema/MicrosoftExtensions.c were not tested. Will look into it later.

Jan 7 2020, 1:08 PM · Restricted Project
Mordante added a comment to D72212: [Sema] Improve -Wrange-loop-analysis warnings.

You're welcome. It would be nice if we can get this one in the release.

Jan 7 2020, 11:31 AM · Restricted Project

Jan 6 2020

Mordante committed rG5e0e0e3ff05f: [NFC] Fixes -Wrange-loop-analysis warnings (authored by Mordante).
[NFC] Fixes -Wrange-loop-analysis warnings
Jan 6 2020, 3:52 PM
Mordante added a comment to D72053: [RFC] Handling implementation limits.

Thanks for the feedback!

Jan 6 2020, 2:44 PM · Restricted Project
Mordante added inline comments to D72053: [RFC] Handling implementation limits.
Jan 6 2020, 8:48 AM · Restricted Project
Mordante committed rGeec0240f9718: Adds -Wrange-loop-analysis to -Wall (authored by Mordante).
Adds -Wrange-loop-analysis to -Wall
Jan 6 2020, 8:39 AM
Mordante committed rG1d549cff48cd: [NFC] Fixes -Wrange-loop-analysis warnings (authored by Mordante).
[NFC] Fixes -Wrange-loop-analysis warnings
Jan 6 2020, 8:38 AM
Mordante closed D72210: [NFC] Fixes -Wrange-loop-analysis warnings.
Jan 6 2020, 8:38 AM · Restricted Project, lld

Jan 5 2020

Mordante added a comment to D72231: [Sema] Adds the pointer-to-int-cast diagnostic.

The diagnostic is not enabled by default

But GCC enables it for C even without "-Wall or -Wextra". Clang should follow it..

Jan 5 2020, 12:16 PM · Restricted Project
Mordante created D72231: [Sema] Adds the pointer-to-int-cast diagnostic.
Jan 5 2020, 11:43 AM · Restricted Project
Mordante updated the diff for D72053: [RFC] Handling implementation limits.

Made some improvements based on feedback of @craig.topper:

  • Adds a not
  • Implements an example of the maximum string length when using -Wpedantic
Jan 5 2020, 7:35 AM · Restricted Project
Mordante added a comment to D72217: [clang-tidy] Added readability-qualified-auto check.

Nice to see this patch! I intended to look at a similar patch, but that's no longer required.

Jan 5 2020, 6:03 AM · Restricted Project, Restricted Project
Mordante updated the diff for D72210: [NFC] Fixes -Wrange-loop-analysis warnings.

Rebased on master. This adds one new fix and removes the ones done by others.

Jan 5 2020, 5:43 AM · Restricted Project, lld
Mordante added inline comments to D72213: [clang-tidy] Add `bugprone-reserved-identifier` to flag usages of reserved C++ names.
Jan 5 2020, 5:25 AM · Restricted Project, Restricted Project
Mordante added inline comments to D72212: [Sema] Improve -Wrange-loop-analysis warnings.
Jan 5 2020, 5:15 AM · Restricted Project

Jan 4 2020

Mordante updated subscribers of D72213: [clang-tidy] Add `bugprone-reserved-identifier` to flag usages of reserved C++ names.

@eugene Please don't use auto when type is spelled in same statement or iterator. do you mean type is not spelled ?

Jan 4 2020, 2:05 PM · Restricted Project, Restricted Project
Mordante added inline comments to D72053: [RFC] Handling implementation limits.
Jan 4 2020, 1:55 PM · Restricted Project
Mordante added inline comments to D72212: [Sema] Improve -Wrange-loop-analysis warnings.
Jan 4 2020, 1:46 PM · Restricted Project
Mordante added a comment to D72213: [clang-tidy] Add `bugprone-reserved-identifier` to flag usages of reserved C++ names.

I like this change, but I don't feel qualified to fully review the patch.

Jan 4 2020, 1:38 PM · Restricted Project, Restricted Project
Mordante added a comment to D72210: [NFC] Fixes -Wrange-loop-analysis warnings.

You can drop changes to lld. I've fixed lld -Wrange-loop-analysis a few days ago in 681b1be774964a804beabfb7c5e3bdab8f979e4a . (Archive::Child c was also deleted).

For mlir, only mlir/lib/Dialect/Linalg/Utils/Utils.cpp:117:8 needs a fix. I've fixed others in eeef50b1fee91dbe993187324003d2665ceae331.

Jan 4 2020, 12:52 PM · Restricted Project, lld
Mordante created D72212: [Sema] Improve -Wrange-loop-analysis warnings.
Jan 4 2020, 12:51 PM · Restricted Project
Mordante accepted D72211: [ELF] Drop const qualifier to fix -Wrange-loop-analysis. NFC.

LGTM
I proposed the same change in D72210, but I'll adjust that patch once accepted.

Jan 4 2020, 12:15 PM · Restricted Project
Mordante created D72210: [NFC] Fixes -Wrange-loop-analysis warnings.
Jan 4 2020, 11:29 AM · Restricted Project, lld
Mordante added a comment to D71857: [NFC] Fixes -Wrange-loop-analysis warnings.

I think there is a false positive.

https://github.com/llvm/llvm-project/tree/master/lld/ELF/Relocations.cpp#L1622

for (const std::pair<ThunkSection *, uint32_t> ts : isd->thunkSections)
Jan 4 2020, 11:20 AM · Restricted Project, Restricted Project, Restricted Project
Mordante updated the diff for D72053: [RFC] Handling implementation limits.

Added support for some additional features:

  • Allow limits from the C standard, either sharing the C++ constants or separately.
  • Allow to document the design choices for the limit.
  • Allow to track the status of the limit. (This may become obsolete ones all limits are implemented, but that can take a while.)
Jan 4 2020, 10:42 AM · Restricted Project

Jan 2 2020

Mordante created D72103: [Sema] Avoid using an invalid InsertPos.
Jan 2 2020, 12:59 PM · Restricted Project
Mordante added a comment to D71857: [NFC] Fixes -Wrange-loop-analysis warnings.

However, I am afraid I don't like some of the fixes here. You can replace const auto with const auto & and call that a fix... IMHO if the type is not obvious, const ConcreteType & will be better.

Jan 2 2020, 11:24 AM · Restricted Project, Restricted Project, Restricted Project

Jan 1 2020

Mordante added a reverting change for rGd8117542ac57: Adds -Wrange-loop-analysis to -Wall: rG8ca79dac5592: Revert "Adds -Wrange-loop-analysis to -Wall".
Jan 1 2020, 1:26 PM
Mordante committed rG8ca79dac5592: Revert "Adds -Wrange-loop-analysis to -Wall" (authored by Mordante).
Revert "Adds -Wrange-loop-analysis to -Wall"
Jan 1 2020, 1:26 PM
Mordante committed rGd8117542ac57: Adds -Wrange-loop-analysis to -Wall (authored by Mordante).
Adds -Wrange-loop-analysis to -Wall
Jan 1 2020, 11:08 AM
Mordante closed D68912: Adds -Wrange-loop-analysis to -Wall.
Jan 1 2020, 11:08 AM · Restricted Project
Mordante committed rGe5ab1e49f958: Improve Wrange-loop-analyses for rvalue reference (authored by Mordante).
Improve Wrange-loop-analyses for rvalue reference
Jan 1 2020, 11:08 AM
Mordante closed D71806: Improve Wrange-loop-analyses for rvalue reference.
Jan 1 2020, 11:08 AM · Restricted Project
Mordante committed rGf022a5a792fd: Adds fixit hints to the -Wrange-loop-analysis (authored by Mordante).
Adds fixit hints to the -Wrange-loop-analysis
Jan 1 2020, 11:08 AM
Mordante closed D68913: Adds fixit hints to the Wrange-loop-analysis.
Jan 1 2020, 11:08 AM · Restricted Project
Mordante committed rG8dc7b982b455: [NFC] Fixes -Wrange-loop-analysis warnings (authored by Mordante).
[NFC] Fixes -Wrange-loop-analysis warnings
Jan 1 2020, 11:07 AM
Mordante closed D71857: [NFC] Fixes -Wrange-loop-analysis warnings.
Jan 1 2020, 11:07 AM · Restricted Project, Restricted Project, Restricted Project
Mordante created D72053: [RFC] Handling implementation limits.
Jan 1 2020, 7:53 AM · Restricted Project
Mordante added a comment to D71857: [NFC] Fixes -Wrange-loop-analysis warnings.

Thanks for the review! I'll commit all the -Wrange-loop-analysis patches later today.

Jan 1 2020, 7:39 AM · Restricted Project, Restricted Project, Restricted Project
Mordante added inline comments to D71857: [NFC] Fixes -Wrange-loop-analysis warnings.
Jan 1 2020, 7:26 AM · Restricted Project, Restricted Project, Restricted Project
Mordante updated the diff for D71857: [NFC] Fixes -Wrange-loop-analysis warnings.

Reviewed the types and added a * for pointers and added a const when applicable.

Jan 1 2020, 7:22 AM · Restricted Project, Restricted Project, Restricted Project
Mordante created D72052: [UserManual] Update the C++ standard support.
Jan 1 2020, 7:17 AM · Restricted Project

Dec 29 2019

Mordante updated the diff for D71966: [Wdocumentation][RFC] Improve identifier's of \param.

Fixes the compilation issues with the clang unit tests.

Dec 29 2019, 11:01 AM · Restricted Project

Dec 28 2019

Mordante added a comment to D71966: [Wdocumentation][RFC] Improve identifier's of \param.

The merge bot noticed I forgot to update clang's unittests. Will look at that.

Dec 28 2019, 12:02 PM · Restricted Project
Mordante created D71966: [Wdocumentation][RFC] Improve identifier's of \param.
Dec 28 2019, 11:16 AM · Restricted Project
Mordante added a comment to D71916: High-Level Code-Review Documentation Update.

Thanks for writing this document! I noticed the document contains a lot of long sentences. These may be harder to understand for non-native speakers. I pointed a few out, but for some I don't have better suggestions.

Dec 28 2019, 7:56 AM · Restricted Project
Mordante added a comment to D71920: [AST] Refactor propagation of dependency bits. NFC.

I like the goal of this patch and the simplifications it does. I don't feel qualified to do a full review.

Dec 28 2019, 7:14 AM · Restricted Project

Dec 24 2019

Mordante created D71857: [NFC] Fixes -Wrange-loop-analysis warnings.
Dec 24 2019, 11:06 AM · Restricted Project, Restricted Project, Restricted Project

Dec 22 2019

Mordante committed rG2d903cc9656d: [AMDGPU] Fixes -Wrange-loop-analysis warnings (authored by Mordante).
[AMDGPU] Fixes -Wrange-loop-analysis warnings
Dec 22 2019, 10:40 AM
Mordante closed D71815: [AMDGPU] Fixes -Wrange-loop-analysis warnings.
Dec 22 2019, 10:40 AM · Restricted Project
Mordante committed rG9c11026c1b01: [Hexagon] Fixes -Wrange-loop-analysis warnings (authored by Mordante).
[Hexagon] Fixes -Wrange-loop-analysis warnings
Dec 22 2019, 10:36 AM
Mordante closed D71814: [Hexagon] Fixes -Wrange-loop-analysis warnings.
Dec 22 2019, 10:36 AM · Restricted Project
Mordante committed rG31262d6722c7: [NVPTX] Fixes -Wrange-loop-analysis warnings (authored by Mordante).
[NVPTX] Fixes -Wrange-loop-analysis warnings
Dec 22 2019, 10:31 AM
Mordante closed D71812: [NVPTX] Fixes -Wrange-loop-analysis warnings.
Dec 22 2019, 10:31 AM · Restricted Project
Mordante committed rG1b344e7967a7: [PowerPC] Fixes -Wrange-loop-analysis warnings (authored by Mordante).
[PowerPC] Fixes -Wrange-loop-analysis warnings
Dec 22 2019, 10:24 AM
Mordante closed D71811: [PowerPC] Fixes -Wrange-loop-analysis warnings.
Dec 22 2019, 10:24 AM · Restricted Project
Mordante committed rG098d3347e74a: [Transforms] Fixes -Wrange-loop-analysis warnings (authored by Mordante).
[Transforms] Fixes -Wrange-loop-analysis warnings
Dec 22 2019, 10:21 AM