xbolva00 (Dávid Bolvanský)
User

Projects

User does not belong to any projects.

User Details

User Since
Apr 5 2018, 5:18 PM (24 w, 3 d)

Recent Activity

Mon, Sep 17

xbolva00 added a comment to D52164: [InstSimplify] Fold ne/eq comparison of a pointer produced by a noalias function.

disable this fold when comparing noalias ptr with null

But it's not just comparing to a nullptr constant, it's also comparing to another SSA value that, dynamically, is null.

Mon, Sep 17, 12:16 PM
xbolva00 added a comment to D52164: [InstSimplify] Fold ne/eq comparison of a pointer produced by a noalias function.

Yes, we only fold if it is not used. :)

Mon, Sep 17, 12:16 PM
xbolva00 added a comment to D52164: [InstSimplify] Fold ne/eq comparison of a pointer produced by a noalias function.

int f(int n) {

int *x = (int *)malloc(n);
free(x);
int *y =  (int *)malloc(n);
return (y == x) ;

}

Mon, Sep 17, 11:15 AM
xbolva00 reclaimed D52164: [InstSimplify] Fold ne/eq comparison of a pointer produced by a noalias function.

Ok.. so maybe

  • disable this fold when comparing noalias ptr with null
  • disable also when cmp' rhs and lhs are both noalias ptrs
Mon, Sep 17, 11:12 AM
xbolva00 abandoned D52164: [InstSimplify] Fold ne/eq comparison of a pointer produced by a noalias function.
Mon, Sep 17, 11:06 AM
xbolva00 updated the diff for D52164: [InstSimplify] Fold ne/eq comparison of a pointer produced by a noalias function.
Mon, Sep 17, 2:00 AM
xbolva00 added a comment to D52164: [InstSimplify] Fold ne/eq comparison of a pointer produced by a noalias function.

Yes, I will add more tests. Suggestions welcome.

Mon, Sep 17, 1:53 AM
xbolva00 created D52164: [InstSimplify] Fold ne/eq comparison of a pointer produced by a noalias function.
Mon, Sep 17, 1:28 AM

Sun, Sep 16

xbolva00 added a comment to D52137: Added warning for unary minus used with unsigned type.

"High bits are zeros" and "result is always non negative" are good candidatates to be catched here. Thanks for detailed review, Richard. Now I will look on it.

Sun, Sep 16, 10:43 PM
xbolva00 added a comment to D52137: Added warning for unary minus used with unsigned type.

MSVC warns for every case in the test file I uploaded here. https://godbolt.org/z/jiMFp6

Sun, Sep 16, 11:41 AM

Sat, Sep 15

xbolva00 added a comment to D52137: Added warning for unary minus used with unsigned type.

Hm, isUnsignedIntegerType seems to ignore uintN_t types?

Sat, Sep 15, 3:39 PM
xbolva00 updated the diff for D52137: Added warning for unary minus used with unsigned type.
Sat, Sep 15, 3:10 PM
xbolva00 updated the diff for D52137: Added warning for unary minus used with unsigned type.

Added fixit hints

Sat, Sep 15, 3:08 PM
xbolva00 added a comment to D52137: Added warning for unary minus used with unsigned type.
Sat, Sep 15, 2:50 PM
xbolva00 added a comment to D52137: Added warning for unary minus used with unsigned type.

I think we can emit fixit hint always, not even for -u32 case :)

Sat, Sep 15, 1:18 PM
xbolva00 added a reviewer for D52137: Added warning for unary minus used with unsigned type: aaron.ballman.
Sat, Sep 15, 1:12 PM
xbolva00 updated the diff for D52137: Added warning for unary minus used with unsigned type.
  1. Error -> Warning
Sat, Sep 15, 11:49 AM
xbolva00 added a comment to D52137: Added warning for unary minus used with unsigned type.

15-20 times / 10 000 lines. I checked and first two are bugs, I don't track other warnings yet.

Sat, Sep 15, 11:41 AM
xbolva00 added a comment to D52137: Added warning for unary minus used with unsigned type.

@RKSimon are fine to rewrite X & -X to X & ((~X)+1) in bmiintrin.h?

Sat, Sep 15, 11:29 AM
xbolva00 added a comment to D52137: Added warning for unary minus used with unsigned type.

The first is not broken, but it is now detected by this new check. I think the second form is more explicit and better.

Sat, Sep 15, 11:23 AM
xbolva00 added inline comments to D52137: Added warning for unary minus used with unsigned type.
Sat, Sep 15, 11:18 AM
xbolva00 updated subscribers of D52137: Added warning for unary minus used with unsigned type.
Sat, Sep 15, 11:16 AM
xbolva00 updated the diff for D52137: Added warning for unary minus used with unsigned type.
Sat, Sep 15, 11:10 AM
xbolva00 updated subscribers of D52137: Added warning for unary minus used with unsigned type.

/home/xbolva00/LLVM/build/lib/clang/8.0.0/include/bmiintrin.h:312:16: error: unary minus operator applied to type 'unsigned long long', result value is still unsigned

return __X & -__X;
Sat, Sep 15, 11:10 AM
xbolva00 created D52137: Added warning for unary minus used with unsigned type.
Sat, Sep 15, 10:58 AM
xbolva00 added a comment to D50039: [LibCalls] Added nonnull atribute to libc function args.

ping

Sat, Sep 15, 9:18 AM
xbolva00 added a comment to D38128: Handle COPYs of physregs better (regalloc hints).

Is this ready or any blockers?

Sat, Sep 15, 3:46 AM

Fri, Sep 14

xbolva00 added a comment to D52109: [TwoAddressInstructionPass] Don't update SrcRegMap for copies inserted for tied register constraint when the src isn't killed.

Looks awesome!

Fri, Sep 14, 11:28 AM
xbolva00 added a comment to D45444: [clang-tidy] implement new check for const-correctness.

Yeah, it would be super useful if Clang can add const to all places where possible :) love this work, great!

Fri, Sep 14, 8:13 AM

Thu, Sep 13

xbolva00 added inline comments to D51502: [X86] Fix register resizings for inline assembly register operands..
Thu, Sep 13, 12:50 PM
xbolva00 added a comment to D51333: Diagnose likely typos in include statements.

Where here, I would love to have a fixint hints for unknown functions.

Thu, Sep 13, 12:07 PM
xbolva00 committed rL342139: Print correctly dependency paths on Windows.
Print correctly dependency paths on Windows
Thu, Sep 13, 7:28 AM
xbolva00 committed rC342139: Print correctly dependency paths on Windows.
Print correctly dependency paths on Windows
Thu, Sep 13, 7:28 AM
This revision was not accepted when it landed; it landed in state Needs Review.
Thu, Sep 13, 7:28 AM
xbolva00 added inline comments to D52025: [TargetLowering] Android has sincos functions.
Thu, Sep 13, 5:31 AM
xbolva00 added inline comments to D52025: [TargetLowering] Android has sincos functions.
Thu, Sep 13, 4:35 AM
xbolva00 added a comment to rL342052: Fix MSVC "not all control paths return a value" warnings. NFCI..

Thanks for fix

Btw, sorry for hijacking, but GCC trunk reports another warning in ArrayRef:

/home/davidbolvansky/trunk/llvm/include/llvm/ADT/ArrayRef.h:102:37: warning: initializing ‘llvm::ArrayRef<int>::Data’ from ‘std::initializer_list<int>::begin’ does not extend the lifetime of the underlying array [-Winit-list-lifetime]
102 | : Data(Vec.begin() == Vec.end() ? (T*)nullptr : Vec.begin()),

Should we worry?

Probably! Has it turned up on a buildbot?

I don't think so since -Winit-list-lifetime is added in GCC 9.0 (as well as -Wdeprecated-copy; I saw some deprecated copy warnings too :/). I will share the list of warnings on llvm bugzilla tomorrow.

Thu, Sep 13, 1:37 AM

Wed, Sep 12

xbolva00 updated the diff for D51847: Print correctly dependency paths on Windows.

Adjusted regexes in two more tests

Wed, Sep 12, 11:50 PM
xbolva00 committed rL342075: Do not create new terminals when launching process on Windows with --no-stdio.
Do not create new terminals when launching process on Windows with --no-stdio
Wed, Sep 12, 12:54 PM
xbolva00 committed rLLDB342075: Do not create new terminals when launching process on Windows with --no-stdio.
Do not create new terminals when launching process on Windows with --no-stdio
Wed, Sep 12, 12:54 PM
xbolva00 closed D51966: Do not create new terminals when launching process on Windows with --no-stdio.
Wed, Sep 12, 12:54 PM
xbolva00 accepted D50222: [CodeGen] [SelectionDAG] More efficient code for X % C == 0 (UREM case).

Seems fine for trunk now..

Wed, Sep 12, 12:11 PM
xbolva00 updated the diff for D51966: Do not create new terminals when launching process on Windows with --no-stdio.
Wed, Sep 12, 9:35 AM
xbolva00 added a comment to D51966: Do not create new terminals when launching process on Windows with --no-stdio.

So basically the hardest problem is to "find a way to get stdio from a process and feed to to LLDB so it shows up when neither --tty nor --no-stdio is set" ..

Wed, Sep 12, 8:55 AM
xbolva00 updated subscribers of D51966: Do not create new terminals when launching process on Windows with --no-stdio.
Wed, Sep 12, 7:58 AM
xbolva00 added a comment to D51966: Do not create new terminals when launching process on Windows with --no-stdio.

We should obey the --tty option here and set CREATE_NEW_CONSOLE if it is set no?

Wed, Sep 12, 7:55 AM
xbolva00 added a comment to rL342052: Fix MSVC "not all control paths return a value" warnings. NFCI..

Thanks for fix

Btw, sorry for hijacking, but GCC trunk reports another warning in ArrayRef:

/home/davidbolvansky/trunk/llvm/include/llvm/ADT/ArrayRef.h:102:37: warning: initializing ‘llvm::ArrayRef<int>::Data’ from ‘std::initializer_list<int>::begin’ does not extend the lifetime of the underlying array [-Winit-list-lifetime]
102 | : Data(Vec.begin() == Vec.end() ? (T*)nullptr : Vec.begin()),

Should we worry?

Probably! Has it turned up on a buildbot?

Wed, Sep 12, 7:52 AM
xbolva00 added a comment to rL342052: Fix MSVC "not all control paths return a value" warnings. NFCI..

Thanks for fix

Wed, Sep 12, 6:57 AM
xbolva00 added a comment to D50323: [GVNHoist] Prune out useless CHI insertions.

Check https://bugs.llvm.org/show_bug.cgi?id=38912

Wed, Sep 12, 5:39 AM
xbolva00 updated the diff for D51847: Print correctly dependency paths on Windows.
  • Fixed failing test
Wed, Sep 12, 3:23 AM
xbolva00 abandoned D51966: Do not create new terminals when launching process on Windows with --no-stdio.

I think the issue here is that on windows we don't have the ability(*) to pipe stdio through lldb, so if you create a process without a console, you will not be able to use see it's output or pass it some input (probably fine for gui apps, but bad for console ones). This means your approach will also make things inconsistent with other platforms, only in a different way. (I don't really have an opinion which one is better/worse.)

(*) I think there is a way to emulate the unix pty behavior on windows, but it is not exactly straight-forward. It involves creating a hidden console and then polling that for changes/keypresses (I don't know the details, but that's how someone once explained it to me).

Wed, Sep 12, 1:41 AM
xbolva00 updated the summary of D51966: Do not create new terminals when launching process on Windows with --no-stdio.
Wed, Sep 12, 1:03 AM
xbolva00 added a reviewer for D51966: Do not create new terminals when launching process on Windows with --no-stdio: stella.stamenova.
Wed, Sep 12, 1:03 AM
xbolva00 created D51966: Do not create new terminals when launching process on Windows with --no-stdio.
Wed, Sep 12, 12:57 AM

Tue, Sep 11

xbolva00 added a comment to D51869: NFC: bit.h don't warn on strict aliasing for GCC <= 7.1.

Please check also https://reviews.llvm.org/rL339521 :)

Tue, Sep 11, 11:38 PM
xbolva00 updated the diff for D51847: Print correctly dependency paths on Windows.

Convert paths to platform native paths

Tue, Sep 11, 11:37 PM
xbolva00 abandoned D51778: Introduce LLVM_HOT.
Tue, Sep 11, 1:54 PM
xbolva00 added a comment to D51847: Print correctly dependency paths on Windows.

Alright I see it. The reason I'm asking is because after your change you're now printing main.o: main.c ../include/lib/test.h. But I wonder if you should instead be printing main.o: main.c ..\include\lib\test.h. It seems like paths that we show to the user should be in the native path style.

Tue, Sep 11, 9:47 AM
xbolva00 added a comment to D51847: Print correctly dependency paths on Windows.

Please see PR38877.

Tue, Sep 11, 9:36 AM
xbolva00 accepted D49488: [LV] Move InterleaveGroup and InterleavedAccessInfo to VectorUtils.h (NFC).

Makes sense. Please rebase before you commit this patch.

Tue, Sep 11, 6:12 AM
xbolva00 accepted D51702: [LoopInterchange] Turn into a loop pass. .

Thanks, looks good.

Tue, Sep 11, 6:08 AM
xbolva00 added a comment to rL341535: Reland [ClangUserExpression][NFC] Removed unused code.

Can we rework GetLanguageForExpr? Or atleast rename it.

Tue, Sep 11, 3:55 AM
xbolva00 added inline comments to D51913: [libFuzzer] [Windows] Include windows.h and psapi.h with lowercase.
Tue, Sep 11, 2:04 AM
xbolva00 added a comment to D51847: Print correctly dependency paths on Windows.

What prints this? How do you exercise this codepath?

Tue, Sep 11, 12:55 AM

Mon, Sep 10

xbolva00 retitled D51847: Print correctly dependency paths on Windows from Print corrent dependency path on Windows to Print correctly dependency paths on Windows.
Mon, Sep 10, 12:39 AM
xbolva00 updated the summary of D51847: Print correctly dependency paths on Windows.
Mon, Sep 10, 12:30 AM
xbolva00 updated the diff for D51847: Print correctly dependency paths on Windows.

Remove some dead code

Mon, Sep 10, 12:30 AM
xbolva00 created D51847: Print correctly dependency paths on Windows.
Mon, Sep 10, 12:23 AM

Sun, Sep 9

xbolva00 updated subscribers of rL341775: Part of PR33222: defer enforcing return type mismatch for dependent.

Maybe worth to put this PR33222's fix to release branch too? (+ https://reviews.llvm.org/rL341778)

Sun, Sep 9, 11:42 PM

Sat, Sep 8

xbolva00 added a comment to D33118: Another version of patch for D25987.

Tests?

Sat, Sep 8, 8:35 AM
xbolva00 committed rL341746: Check if a terminal supports colors on Windows properly.
Check if a terminal supports colors on Windows properly
Sat, Sep 8, 12:18 AM
xbolva00 committed rLLDB341746: Check if a terminal supports colors on Windows properly.
Check if a terminal supports colors on Windows properly
Sat, Sep 8, 12:18 AM
xbolva00 closed D51772: Check if a terminal supports colors on Windows properly.
Sat, Sep 8, 12:18 AM
xbolva00 closed D51772: Check if a terminal supports colors on Windows properly.
Sat, Sep 8, 12:18 AM
xbolva00 removed a reviewer for D51778: Introduce LLVM_HOT: rsmmr.
Sat, Sep 8, 12:18 AM
xbolva00 added a reviewer for D51778: Introduce LLVM_HOT: rsmith.
Sat, Sep 8, 12:14 AM
xbolva00 added reviewers for D51778: Introduce LLVM_HOT: rsmmr, dexonsmith.
Sat, Sep 8, 12:14 AM

Fri, Sep 7

xbolva00 added a reviewer for D51505: [WIP][IPSCCP] Use PredInfo to propagate nonnull and hook it up to IPSCCP.: efriedma.
Fri, Sep 7, 5:09 AM
xbolva00 created D51778: Introduce LLVM_HOT.
Fri, Sep 7, 4:32 AM
xbolva00 added a comment to D49858: [RFC] re-enable GVNHoist by default.

Please check https://bugs.llvm.org/show_bug.cgi?id=38807

Fri, Sep 7, 12:50 AM
xbolva00 created D51772: Check if a terminal supports colors on Windows properly.
Fri, Sep 7, 12:02 AM

Thu, Sep 6

xbolva00 added a comment to D51615: Set Windows console mode to enable support for ansi escape codes.

Bot sure how to fix tests since this is somehow hard to problematic.

I think the fix for this is simply to not make the call to SetUseColor here. Is there a reason for the call? It looks like the check for "dumb" terminal and "GetIsTerminalWithColors" might have to come after setting the ANSI escape codes if setting the codes impacts those two cases.

We may disable "use color" setting thanks to GetIsTerminalWithColors but then we realize that we can "enable it" via SetConsoleMode for newer Win 10, so we need to call it I think. The reverse order does not help us either.. I think.

Sounds like GetIsTerminalWithColors might have to be updated to include the new logic as well. Would you rather commit a fix or revert the change and then commit a new one?

Thu, Sep 6, 2:51 PM
xbolva00 added a comment to D51615: Set Windows console mode to enable support for ansi escape codes.

Bot sure how to fix tests since this is somehow hard to problematic.

I think the fix for this is simply to not make the call to SetUseColor here. Is there a reason for the call? It looks like the check for "dumb" terminal and "GetIsTerminalWithColors" might have to come after setting the ANSI escape codes if setting the codes impacts those two cases.

Thu, Sep 6, 2:38 PM
xbolva00 added a comment to D51615: Set Windows console mode to enable support for ansi escape codes.

Bot sure how to fix tests since this is somehow hard to problematic.

Thu, Sep 6, 1:49 PM
xbolva00 added a comment to D45653: [X86] Enable sibling-call optimization for functions returning structs.

We should not abandon it. It seems we can optimize this case

Thu, Sep 6, 7:06 AM
xbolva00 updated subscribers of D50534: [libc++] Fix handling of negated character classes in regex.

is this fixed in 7.0 release branch too?

Thu, Sep 6, 12:12 AM

Wed, Sep 5

xbolva00 committed rLLDB341497: Set Windows console mode to enable support for ansi escape codes.
Set Windows console mode to enable support for ansi escape codes
Wed, Sep 5, 3:10 PM
xbolva00 committed rL341497: Set Windows console mode to enable support for ansi escape codes.
Set Windows console mode to enable support for ansi escape codes
Wed, Sep 5, 3:10 PM
This revision was not accepted when it landed; it landed in state Needs Review.
Wed, Sep 5, 3:10 PM
xbolva00 updated the diff for D51615: Set Windows console mode to enable support for ansi escape codes.
  • Check for _WIN32
Wed, Sep 5, 9:42 AM
xbolva00 updated the diff for D51615: Set Windows console mode to enable support for ansi escape codes.
Wed, Sep 5, 9:38 AM
xbolva00 updated the diff for D51615: Set Windows console mode to enable support for ansi escape codes.
  • use llvm::sys::Process::UseANSIEscapeCodes
Wed, Sep 5, 9:24 AM
xbolva00 added a comment to D51615: Set Windows console mode to enable support for ansi escape codes.

@teemperor please take a look again :)

Wed, Sep 5, 7:02 AM

Tue, Sep 4

xbolva00 added a comment to D50233: [InstCombine] Transform str(n)cmp to memcmp.

So what is proposed solution?

Tue, Sep 4, 10:48 PM
xbolva00 added a comment to D50233: [InstCombine] Transform str(n)cmp to memcmp.

But that also implies that you have to emit an inline implementation since you might not control what the implementation of memcmp supplied by libc does?

Assuming there isn't a data race, the libc implementation of memcmp can't actually do anything undefined. In assembly, "uninitialized" data always has some fixed value.


Given the problems here, we probably want to move this transform to the ExpandMemCmp pass, and only transform when we'll expand the compare inline.

Tue, Sep 4, 1:13 PM
xbolva00 added inline comments to D51393: Provide a method for generating deterministic IDs for pointers allocated in BumpPtrAllocator.
Tue, Sep 4, 12:48 PM
xbolva00 added a comment to D50233: [InstCombine] Transform str(n)cmp to memcmp.

Does LLVM's implementation somehow guarantee that no later optimization pass comes along, sees the program reading uninitialized memory and declares UB?

In LLVM IR, reading uninitialized memory isn't itself UB; it's only UB if you perform certain operations on the result. Granted, a naive LLVM IR implementation of memcmp might involve operations which lead to UB.

But that also implies that you have to emit an inline implementation since you might not control what the implementation of memcmp supplied by libc does?

Tue, Sep 4, 12:45 PM
xbolva00 committed rL341396: Set console mode when -fansi-escape-codes is enabled .
Set console mode when -fansi-escape-codes is enabled
Tue, Sep 4, 12:24 PM
xbolva00 closed D51611: Set console mode when -fansi-escape-codes is enabled .
Tue, Sep 4, 12:24 PM
xbolva00 added a comment to D50233: [InstCombine] Transform str(n)cmp to memcmp.

GCC does not have MemorySanitizer.

Tue, Sep 4, 12:10 PM