Page MenuHomePhabricator

Carrot (Guozhi Wei)
User

Projects

User does not belong to any projects.

User Details

User Since
Jul 15 2015, 3:50 PM (299 w, 4 d)

Recent Activity

Thu, Mar 25

Carrot committed rG3240910f0006: [DAE] Adjust param/arg attributes when changing parameter to undef (authored by Carrot).
[DAE] Adjust param/arg attributes when changing parameter to undef
Thu, Mar 25, 2:54 PM
Carrot closed D98899: [DAE] Adjust param/arg attributes when changing parameter to undef.
Thu, Mar 25, 2:54 PM · Restricted Project

Wed, Mar 24

Carrot updated the diff for D98899: [DAE] Adjust param/arg attributes when changing parameter to undef.

Thanks for the improvement.
Will commit this version.

Wed, Mar 24, 11:33 AM · Restricted Project

Tue, Mar 23

Carrot updated the diff for D98899: [DAE] Adjust param/arg attributes when changing parameter to undef.

Reformat the patch.

Tue, Mar 23, 3:20 PM · Restricted Project

Mon, Mar 22

Carrot updated the diff for D98899: [DAE] Adjust param/arg attributes when changing parameter to undef.
Mon, Mar 22, 6:40 PM · Restricted Project
Carrot added a comment to D98899: [DAE] Adjust param/arg attributes when changing parameter to undef.

This looks reasonable to me. Dropping nonnull is not strictly necessary (because it has no immediate UB), but doesn't hurt either.

I was going to suggest using AttrBuilder to drop all attributes at once, but I'm not sure that works with dereferenceable attributes.

Mon, Mar 22, 6:39 PM · Restricted Project

Fri, Mar 19

Carrot added a reviewer for D98899: [DAE] Adjust param/arg attributes when changing parameter to undef: petarj.
Fri, Mar 19, 5:19 PM · Restricted Project

Thu, Mar 18

Carrot requested review of D98899: [DAE] Adjust param/arg attributes when changing parameter to undef.
Thu, Mar 18, 2:29 PM · Restricted Project

Tue, Mar 16

Carrot added inline comments to D97244: [SimplifyCFG] Update passingValueIsAlwaysUndefined to check more attributes.
Tue, Mar 16, 6:04 PM · Restricted Project
Carrot added inline comments to D97244: [SimplifyCFG] Update passingValueIsAlwaysUndefined to check more attributes.
Tue, Mar 16, 5:17 PM · Restricted Project

Feb 18 2021

Carrot committed rG66f2d09ebf8d: [DAGCombiner] Transform (zext (select c, load1, load2)) -> (select c, zextload1… (authored by Carrot).
[DAGCombiner] Transform (zext (select c, load1, load2)) -> (select c, zextload1…
Feb 18 2021, 1:16 PM
Carrot closed D95086: [DAGCombiner] Transform (zext (select c, load1, load2)) -> (select c, zextload1, zextload2).
Feb 18 2021, 1:16 PM · Restricted Project
Carrot committed rG2cc76b17be47: Pre-commit test case (authored by Carrot).
Pre-commit test case
Feb 18 2021, 11:08 AM

Feb 11 2021

Carrot added a comment to rG69bc0990a918: [DAGCombiner] Enable SimplifyDemandedBits vector support for TRUNCATE….

Compile the following cpp code

Feb 11 2021, 3:42 PM

Feb 10 2021

Carrot added inline comments to D95086: [DAGCombiner] Transform (zext (select c, load1, load2)) -> (select c, zextload1, zextload2).
Feb 10 2021, 3:53 PM · Restricted Project
Carrot updated the diff for D95086: [DAGCombiner] Transform (zext (select c, load1, load2)) -> (select c, zextload1, zextload2).

ANY_EXTEND of SEXTLOAD/ZEXTLOAD should not be allowed.
In theory if both loads have same SEXTLOAD/ZEXTLOAD, we can change ExpOpcode to corresponding SIGN_EXTEND/ZERO_EXTEND, but it will make the code more complex, and this case should be extremely rare.

Feb 10 2021, 3:52 PM · Restricted Project

Feb 5 2021

Carrot added a comment to D95086: [DAGCombiner] Transform (zext (select c, load1, load2)) -> (select c, zextload1, zextload2).

ping

Feb 5 2021, 8:12 PM · Restricted Project

Jan 29 2021

Carrot updated the diff for D95086: [DAGCombiner] Transform (zext (select c, load1, load2)) -> (select c, zextload1, zextload2).

Check conflicting extload.

Jan 29 2021, 1:51 PM · Restricted Project

Jan 28 2021

Carrot updated the diff for D95086: [DAGCombiner] Transform (zext (select c, load1, load2)) -> (select c, zextload1, zextload2).
Jan 28 2021, 6:38 PM · Restricted Project
Carrot updated the diff for D95086: [DAGCombiner] Transform (zext (select c, load1, load2)) -> (select c, zextload1, zextload2).

Add support for ISD::VSELECT.

Jan 28 2021, 5:21 PM · Restricted Project
Carrot updated the diff for D95086: [DAGCombiner] Transform (zext (select c, load1, load2)) -> (select c, zextload1, zextload2).

Rebase the test case.

Jan 28 2021, 10:20 AM · Restricted Project

Jan 27 2021

Carrot added inline comments to D95086: [DAGCombiner] Transform (zext (select c, load1, load2)) -> (select c, zextload1, zextload2).
Jan 27 2021, 5:33 PM · Restricted Project
Carrot updated the diff for D95086: [DAGCombiner] Transform (zext (select c, load1, load2)) -> (select c, zextload1, zextload2).

Add more test cases.

Jan 27 2021, 5:33 PM · Restricted Project

Jan 26 2021

Carrot added inline comments to D95086: [DAGCombiner] Transform (zext (select c, load1, load2)) -> (select c, zextload1, zextload2).
Jan 26 2021, 6:15 PM · Restricted Project
Carrot added a reviewer for D95086: [DAGCombiner] Transform (zext (select c, load1, load2)) -> (select c, zextload1, zextload2): craig.topper.
Jan 26 2021, 11:16 AM · Restricted Project

Jan 21 2021

Carrot updated the diff for D95086: [DAGCombiner] Transform (zext (select c, load1, load2)) -> (select c, zextload1, zextload2).

Rebase the code.

Jan 21 2021, 1:38 PM · Restricted Project

Jan 20 2021

Carrot committed rG96296d9220ee: [DAGCombiner] Precommit test case for D95086 (authored by Carrot).
[DAGCombiner] Precommit test case for D95086
Jan 20 2021, 5:17 PM
Carrot closed D95103: [DAGCombiner] Precommit test case for D95086.
Jan 20 2021, 5:17 PM · Restricted Project
Carrot requested review of D95103: [DAGCombiner] Precommit test case for D95086.
Jan 20 2021, 3:41 PM · Restricted Project
Carrot requested review of D95086: [DAGCombiner] Transform (zext (select c, load1, load2)) -> (select c, zextload1, zextload2).
Jan 20 2021, 1:14 PM · Restricted Project

Jan 19 2021

Carrot added a comment to D94851: [InstCombine] Don't transform (select c, ext(TI), ext(FI)) if ext is free.

Thanks for the info.

I will discard this patch and reverse the pattern at function CodeGenPrepare::optimizeExt.

Not really sure why that would go into CodeGenPrepare, which is a temporary hack,
DAGCombine is the usual counterpart.

Jan 19 2021, 2:02 PM · Restricted Project
Carrot abandoned D94851: [InstCombine] Don't transform (select c, ext(TI), ext(FI)) if ext is free.
Jan 19 2021, 1:04 PM · Restricted Project
Carrot added a comment to D94851: [InstCombine] Don't transform (select c, ext(TI), ext(FI)) if ext is free.

Thanks for the info.

Jan 19 2021, 1:04 PM · Restricted Project

Jan 15 2021

Carrot requested review of D94851: [InstCombine] Don't transform (select c, ext(TI), ext(FI)) if ext is free.
Jan 15 2021, 6:04 PM · Restricted Project

Jan 13 2021

Carrot added a comment to D43256: [MBP] Move a latch block with conditional exit and multi predecessors to top of loop.

Is this a general problem with MBP then? I haven't noticed it before this optimization, but maybe it was just luck or not investigating the right examples. I'm trying to understand where is the best place to fix it, and if it's even feasible.

Jan 13 2021, 12:35 PM · Restricted Project

Jan 12 2021

Carrot added a comment to D43256: [MBP] Move a latch block with conditional exit and multi predecessors to top of loop.

@GalZohar, thanks for the example, now I understand your problem. The new layout does increase the number of executed branches for the path BB2->BB3->BB4->BB2. Unfortunately most of the current MBP algorithms don't consider this factor. When considering the number of fall through only, the new layout has more fall through and less taken branch.

Jan 12 2021, 6:22 PM · Restricted Project

Jan 8 2021

Carrot added a comment to D43256: [MBP] Move a latch block with conditional exit and multi predecessors to top of loop.

@GalZohar, without a testcase I can't say what's the problem.

Jan 8 2021, 10:24 AM · Restricted Project

Jan 5 2021

Carrot added a comment to D43256: [MBP] Move a latch block with conditional exit and multi predecessors to top of loop.

@GalZohar, the various layout algorithms in MachineBlockPlacement mainly consider the number of fall-throughs and dynamic number of branch instructions (usually they are consistent) according to branch probabilities. So you can try to build your application with profiling. Or you can compile this file with -Os since the improvement in this patch is disabled with -Os.

Jan 5 2021, 2:59 PM · Restricted Project

Dec 16 2020

Carrot committed rG687e80be7fcf: [MBP] Add whole chain to BlockFilterSet instead of individual BB (authored by Carrot).
[MBP] Add whole chain to BlockFilterSet instead of individual BB
Dec 16 2020, 3:46 PM

Dec 15 2020

Carrot added a comment to D89088: [MBP] Add whole chain to BlockFilterSet instead of individual BB.

The real root cause of crash in building chrome and firefox has been committed https://reviews.llvm.org/D92882.

Dec 15 2020, 3:32 PM · Restricted Project

Dec 14 2020

Carrot committed rGd50d7c37a159: [MBP] Prevent rotating a chain contains entry block (authored by Carrot).
[MBP] Prevent rotating a chain contains entry block
Dec 14 2020, 12:50 PM
Carrot closed D92882: [MBP] Prevent rotating a chain contains entry block.
Dec 14 2020, 12:49 PM · Restricted Project

Dec 11 2020

Carrot updated the diff for D92882: [MBP] Prevent rotating a chain contains entry block.

Will commit this version.

Dec 11 2020, 1:41 PM · Restricted Project

Dec 10 2020

Carrot added a comment to D92882: [MBP] Prevent rotating a chain contains entry block.

It is possible to synthesize a test case that rotates the entry without the fix, no? The expected output is that the entry is not rotated (no need to reproduce crash).

Dec 10 2020, 5:57 PM · Restricted Project

Dec 9 2020

Carrot added a comment to D92882: [MBP] Prevent rotating a chain contains entry block.

yes, a test case please :) Any performance numbers?

Dec 9 2020, 4:24 PM · Restricted Project
Carrot added a comment to D92882: [MBP] Prevent rotating a chain contains entry block.

Can we add a test for this?

Dec 9 2020, 4:18 PM · Restricted Project

Dec 8 2020

Carrot requested review of D92882: [MBP] Prevent rotating a chain contains entry block.
Dec 8 2020, 1:32 PM · Restricted Project

Dec 7 2020

Carrot added a comment to D92701: [SLPVectorize] Call isLegalMaskedGather before creating a gather TreeEntry.

@RKSimon, thank you for your help. I do have another test case that has bad vectorization with scatters, https://bugs.llvm.org/show_bug.cgi?id=48429.

Dec 7 2020, 10:23 AM · Restricted Project
Carrot added a comment to D92701: [SLPVectorize] Call isLegalMaskedGather before creating a gather TreeEntry.

@fhahn, thank you for the clarification of the isLegalMaskedGather and getGatherScatterOpCost usage.

Dec 7 2020, 9:22 AM · Restricted Project

Dec 4 2020

Carrot added a reviewer for D92701: [SLPVectorize] Call isLegalMaskedGather before creating a gather TreeEntry: fhahn.
Dec 4 2020, 3:33 PM · Restricted Project
Carrot added a reviewer for D92701: [SLPVectorize] Call isLegalMaskedGather before creating a gather TreeEntry: anton-afanasyev.
Dec 4 2020, 3:31 PM · Restricted Project
Carrot requested review of D92701: [SLPVectorize] Call isLegalMaskedGather before creating a gather TreeEntry.
Dec 4 2020, 3:27 PM · Restricted Project

Nov 13 2020

Carrot committed rGa20220d25b01: [AlwaysInliner] Call mergeAttributesForInlining after inlining (authored by Carrot).
[AlwaysInliner] Call mergeAttributesForInlining after inlining
Nov 13 2020, 12:02 PM
Carrot closed D91446: [AlwaysInliner] Call mergeAttributesForInlining after inlining.
Nov 13 2020, 12:02 PM · Restricted Project
Carrot requested review of D91446: [AlwaysInliner] Call mergeAttributesForInlining after inlining.
Nov 13 2020, 10:51 AM · Restricted Project

Oct 29 2020

Carrot added a comment to D89088: [MBP] Add whole chain to BlockFilterSet instead of individual BB.

In case it helps, I turned on debug logging for this pass on our repro: https://paste.mozilla.org/HBDkeGXO (starts at line 60)

Oct 29 2020, 2:51 PM · Restricted Project

Oct 22 2020

Carrot added a comment to D89088: [MBP] Add whole chain to BlockFilterSet instead of individual BB.

It has been reverted.

Oct 22 2020, 5:39 PM · Restricted Project
Carrot added a comment to D89088: [MBP] Add whole chain to BlockFilterSet instead of individual BB.

@aeubanks, can you extract a test case from your failure?
It will be very helpful for me to debug the problem.

Oct 22 2020, 8:41 AM · Restricted Project

Oct 21 2020

Carrot added a comment to D89088: [MBP] Add whole chain to BlockFilterSet instead of individual BB.

Then it should be an unknown bug in MBP.

Oct 21 2020, 5:21 PM · Restricted Project

Oct 20 2020

Carrot added a comment to D89088: [MBP] Add whole chain to BlockFilterSet instead of individual BB.

As jmorse has pointed out, the function layout is incorrect at the assertion time.

Oct 20 2020, 5:54 PM · Restricted Project

Oct 16 2020

Carrot added a comment to D89088: [MBP] Add whole chain to BlockFilterSet instead of individual BB.

@dmajor, without a test case it is difficult to point out what's wrong since there is no obvious relation between this patch and VarLocBasedImpl.cpp. I will try my best to do some simple analysis/guess:

Oct 16 2020, 1:19 PM · Restricted Project

Oct 14 2020

Carrot committed rGadfb5415010f: [MBP] Add whole chain to BlockFilterSet instead of individual BB (authored by Carrot).
[MBP] Add whole chain to BlockFilterSet instead of individual BB
Oct 14 2020, 11:55 AM
Carrot closed D89088: [MBP] Add whole chain to BlockFilterSet instead of individual BB.
Oct 14 2020, 11:55 AM · Restricted Project

Oct 13 2020

Carrot added a comment to D89088: [MBP] Add whole chain to BlockFilterSet instead of individual BB.

For the attached test case, it can cause bad layout, block .problem is placed under .cold. With this patch .problem is optimally placed after .pred.

Oct 13 2020, 4:34 PM · Restricted Project
Carrot added inline comments to D89088: [MBP] Add whole chain to BlockFilterSet instead of individual BB.
Oct 13 2020, 2:25 PM · Restricted Project

Oct 8 2020

Carrot requested review of D89088: [MBP] Add whole chain to BlockFilterSet instead of individual BB.
Oct 8 2020, 6:14 PM · Restricted Project

Sep 23 2020

Carrot committed rGfd75ad86624e: [MBFIWrapper] Add a new function getBlockProfileCount (authored by Carrot).
[MBFIWrapper] Add a new function getBlockProfileCount
Sep 23 2020, 9:32 AM
Carrot closed D87802: [MBFIWrapper] Add a new function getBlockProfileCount.
Sep 23 2020, 9:32 AM · Restricted Project

Sep 22 2020

Carrot added inline comments to D87802: [MBFIWrapper] Add a new function getBlockProfileCount.
Sep 22 2020, 12:00 PM · Restricted Project

Sep 21 2020

Carrot updated the diff for D87802: [MBFIWrapper] Add a new function getBlockProfileCount.
Sep 21 2020, 5:09 PM · Restricted Project

Sep 17 2020

Carrot added a comment to D87802: [MBFIWrapper] Add a new function getBlockProfileCount.

It can be triggered by a test case in my next basic block duplication patch, because newly created basic block can cause MBFI.getBlockProfileCount crash.

Sep 17 2020, 5:26 PM · Restricted Project

Sep 16 2020

Carrot requested review of D87802: [MBFIWrapper] Add a new function getBlockProfileCount.
Sep 16 2020, 3:58 PM · Restricted Project

Sep 15 2020

Carrot committed rG243ffd0cade7: [MachineBasicBlock] Fix a typo in function copySuccessor (authored by Carrot).
[MachineBasicBlock] Fix a typo in function copySuccessor
Sep 15 2020, 9:19 AM
Carrot closed D87417: [MachineBasicBlock] Fix a typo in function copySuccessor.
Sep 15 2020, 9:19 AM · Restricted Project

Sep 10 2020

Carrot added a reviewer for D87417: [MachineBasicBlock] Fix a typo in function copySuccessor: xur.
Sep 10 2020, 1:00 PM · Restricted Project

Sep 9 2020

Carrot requested review of D87417: [MachineBasicBlock] Fix a typo in function copySuccessor.
Sep 9 2020, 2:51 PM · Restricted Project

Aug 27 2020

Carrot added a comment to D85007: [PowerPC] PPCBoolRetToInt: Don't translate Constant's operands.

LGTM

Aug 27 2020, 8:51 AM · Restricted Project
Carrot accepted D85007: [PowerPC] PPCBoolRetToInt: Don't translate Constant's operands.
Aug 27 2020, 8:51 AM · Restricted Project

Aug 26 2020

Carrot added a comment to D85007: [PowerPC] PPCBoolRetToInt: Don't translate Constant's operands.

Please also update your patch description. Otherwise it looks good to me.

Aug 26 2020, 11:19 AM · Restricted Project

Aug 24 2020

Carrot added a comment to D85007: [PowerPC] PPCBoolRetToInt: Don't translate Constant's operands.

I think your test case is a perfect candidate for this optimization. It should not be skipped.

Aug 24 2020, 11:12 PM · Restricted Project

Jul 21 2020

Carrot committed rG28759e9fcc44: [MBP] Use profile count to compute tail dup cost if it is available (authored by Carrot).
[MBP] Use profile count to compute tail dup cost if it is available
Jul 21 2020, 11:19 AM
Carrot closed D83265: [MBP] Use profile count to compute tail dup cost if it is available.
Jul 21 2020, 11:19 AM · Restricted Project

Jul 20 2020

Carrot updated the diff for D83265: [MBP] Use profile count to compute tail dup cost if it is available.

Will commit this version.

Jul 20 2020, 9:16 PM · Restricted Project

Jul 17 2020

Carrot added inline comments to D83265: [MBP] Use profile count to compute tail dup cost if it is available.
Jul 17 2020, 3:42 PM · Restricted Project
Carrot updated the diff for D83265: [MBP] Use profile count to compute tail dup cost if it is available.
Jul 17 2020, 3:42 PM · Restricted Project

Jul 13 2020

Carrot updated the diff for D83265: [MBP] Use profile count to compute tail dup cost if it is available.
Jul 13 2020, 6:30 PM · Restricted Project
Carrot added a comment to D83265: [MBP] Use profile count to compute tail dup cost if it is available.

A few things:

  1. can this be extended to the TailDup pass too?

This patch only changes the cost function, it doesn't change tail dup algorithms, especially the partial duplication is not implemented in TailDup pass.

Jul 13 2020, 6:27 PM · Restricted Project

Jul 6 2020

Herald added a project to D83265: [MBP] Use profile count to compute tail dup cost if it is available: Restricted Project.
Jul 6 2020, 4:45 PM · Restricted Project

Jun 19 2020

Carrot added a comment to D76194: [BasicAA] Use known lower bounds for index values for size based check..

@fhahn, could you help to take a look at https://bugs.llvm.org/show_bug.cgi?id=46335? It may be caused by this patch.

Jun 19 2020, 12:32 PM · Restricted Project

Jun 9 2020

Carrot added a comment to D68414: [SROA] Enhance AggLoadStoreRewriter to rewrite integer load/store if it covers multi fields in original aggregate.

ping

Jun 9 2020, 7:20 PM · Restricted Project

Jun 2 2020

Carrot committed rG587af86f1d8a: [X86] Add a flag to guard the wide load (authored by Carrot).
[X86] Add a flag to guard the wide load
Jun 2 2020, 4:30 PM
Carrot closed D80943: [X86] Add a flag to guard the wide load.
Jun 2 2020, 4:29 PM · Restricted Project
Carrot added a reviewer for D80943: [X86] Add a flag to guard the wide load: craig.topper.
Jun 2 2020, 11:32 AM · Restricted Project

Jun 1 2020

Carrot updated the diff for D80943: [X86] Add a flag to guard the wide load.
Jun 1 2020, 4:16 PM · Restricted Project
Carrot added a comment to D80943: [X86] Add a flag to guard the wide load.

See https://reviews.llvm.org/rL51019 for the original commit.

The benefits of matching loadi32 like this are:

  1. mov is one byte shorter than movzx
  2. We can fold the load into a subsequent 32-bit instruction in some cases.

And the downside, of course, is that if we're unlucky and create a hazard, there's a performance hit.

Jun 1 2020, 4:16 PM · Restricted Project
Carrot created D80943: [X86] Add a flag to guard the wide load.
Jun 1 2020, 11:52 AM · Restricted Project

May 29 2020

Carrot committed rG40c08367e411: [DAGCombiner] Add command line options to guard store width reduction… (authored by Carrot).
[DAGCombiner] Add command line options to guard store width reduction…
May 29 2020, 9:48 AM
Carrot closed D80745: [DAGCombiner] Add a command line option to guard ReduceLoadOpStoreWidth.
May 29 2020, 9:47 AM · Restricted Project

May 28 2020

Carrot updated the diff for D80745: [DAGCombiner] Add a command line option to guard ReduceLoadOpStoreWidth.
May 28 2020, 3:59 PM · Restricted Project
Carrot added inline comments to D80745: [DAGCombiner] Add a command line option to guard ReduceLoadOpStoreWidth.
May 28 2020, 3:59 PM · Restricted Project