Page MenuHomePhabricator

congzhe (Congzhe Cao)
User

Projects

User does not belong to any projects.

User Details

User Since
Jan 2 2020, 7:36 AM (41 w, 6 d)

Recent Activity

Wed, Sep 30

congzhe updated the diff for D86956: [AArch64] Avoid pairing loads when the base reg is modified.
Wed, Sep 30, 8:55 AM · Restricted Project, Restricted Project, Restricted Project
congzhe updated the diff for D86956: [AArch64] Avoid pairing loads when the base reg is modified.
Wed, Sep 30, 8:50 AM · Restricted Project, Restricted Project, Restricted Project
congzhe added a comment to D86956: [AArch64] Avoid pairing loads when the base reg is modified.

Thanks for all the comments, now addressed all of them @fhahn

Wed, Sep 30, 7:23 AM · Restricted Project, Restricted Project, Restricted Project
congzhe updated the diff for D86956: [AArch64] Avoid pairing loads when the base reg is modified.
Wed, Sep 30, 7:20 AM · Restricted Project, Restricted Project, Restricted Project

Tue, Sep 29

congzhe added a comment to D86956: [AArch64] Avoid pairing loads when the base reg is modified.

@fhahn pinging reviewers :)

Tue, Sep 29, 9:44 PM · Restricted Project, Restricted Project, Restricted Project

Sep 20 2020

congzhe added inline comments to D86956: [AArch64] Avoid pairing loads when the base reg is modified.
Sep 20 2020, 9:28 PM · Restricted Project, Restricted Project, Restricted Project
congzhe updated the diff for D86956: [AArch64] Avoid pairing loads when the base reg is modified.
Sep 20 2020, 9:11 PM · Restricted Project, Restricted Project, Restricted Project
congzhe updated the diff for D86906: [AArch64] Avoid pairing loads with same result reg.
Sep 20 2020, 9:11 PM · Restricted Project, Restricted Project, Restricted Project

Sep 18 2020

congzhe added a comment to D86906: [AArch64] Avoid pairing loads with same result reg.

oh, it might be good to slightly adjust the commit message to be a bit more compact and also mention what actual bug is fixed, e.g. something like [AArch64] Avoid paring loads with same result reg.

Sep 18 2020, 11:45 AM · Restricted Project, Restricted Project, Restricted Project

Sep 17 2020

congzhe retitled D86956: [AArch64] Avoid pairing loads when the base reg is modified from [AArch64LoadStoreOptimization] Bug fix in ldr to ldp conversion to [AArch64] Avoid pairing loads when the base reg is modified.
Sep 17 2020, 3:58 PM · Restricted Project, Restricted Project, Restricted Project
congzhe retitled D86906: [AArch64] Avoid pairing loads with same result reg from [AArch64LdStOptimzation] fix a bug in AArch64 Load Store Optimization to [AArch64] Avoid pairing loads with same result reg.
Sep 17 2020, 3:50 PM · Restricted Project, Restricted Project, Restricted Project
congzhe added inline comments to D86906: [AArch64] Avoid pairing loads with same result reg.
Sep 17 2020, 4:29 AM · Restricted Project, Restricted Project, Restricted Project
congzhe updated the diff for D86956: [AArch64] Avoid pairing loads when the base reg is modified.
Sep 17 2020, 4:28 AM · Restricted Project, Restricted Project, Restricted Project
congzhe added inline comments to D86906: [AArch64] Avoid pairing loads with same result reg.
Sep 17 2020, 4:27 AM · Restricted Project, Restricted Project, Restricted Project
congzhe updated the diff for D86906: [AArch64] Avoid pairing loads with same result reg.
Sep 17 2020, 4:26 AM · Restricted Project, Restricted Project, Restricted Project

Sep 16 2020

congzhe updated the diff for D86956: [AArch64] Avoid pairing loads when the base reg is modified.
Sep 16 2020, 3:10 PM · Restricted Project, Restricted Project, Restricted Project
congzhe added a comment to D86956: [AArch64] Avoid pairing loads when the base reg is modified.

Further reduced the mir test case.

Sep 16 2020, 12:25 PM · Restricted Project, Restricted Project, Restricted Project
congzhe added inline comments to D86906: [AArch64] Avoid pairing loads with same result reg.
Sep 16 2020, 12:24 PM · Restricted Project, Restricted Project, Restricted Project
congzhe updated the diff for D86956: [AArch64] Avoid pairing loads when the base reg is modified.
Sep 16 2020, 12:22 PM · Restricted Project, Restricted Project, Restricted Project
congzhe updated the diff for D86906: [AArch64] Avoid pairing loads with same result reg.
Sep 16 2020, 12:21 PM · Restricted Project, Restricted Project, Restricted Project

Sep 10 2020

congzhe added a comment to D86956: [AArch64] Avoid pairing loads when the base reg is modified.

Is it possible to add a MIR test for the issue? Also, it looks like the formatting is off a bit. Could you run clang-format-diff on the change?

Sep 10 2020, 2:49 PM · Restricted Project, Restricted Project, Restricted Project
congzhe updated the diff for D86956: [AArch64] Avoid pairing loads when the base reg is modified.

Revision:

  • Fixed code style
  • Provided an mir test
Sep 10 2020, 2:47 PM · Restricted Project, Restricted Project, Restricted Project
congzhe added inline comments to D86906: [AArch64] Avoid pairing loads with same result reg.
Sep 10 2020, 2:45 PM · Restricted Project, Restricted Project, Restricted Project
congzhe updated the diff for D86906: [AArch64] Avoid pairing loads with same result reg.

Revision:

  • Fixed code style
  • Reduce the length of the test file
Sep 10 2020, 2:39 PM · Restricted Project, Restricted Project, Restricted Project

Sep 2 2020

congzhe updated the diff for D84220: [IPSCCP] Fix a bug that the "returned" attribute is not cleared when function is optimized to return undef.
Sep 2 2020, 7:56 AM · Restricted Project, Restricted Project

Sep 1 2020

congzhe added a comment to D84220: [IPSCCP] Fix a bug that the "returned" attribute is not cleared when function is optimized to return undef.

rebased and clang format-ed the code, ready to merge

great, thanks! As mentioned earlier, please let us know here if you need someone to commit this change on your behalf, with the name/email you'd like the author field set to.

Sep 1 2020, 11:58 AM · Restricted Project, Restricted Project
congzhe updated the diff for D84220: [IPSCCP] Fix a bug that the "returned" attribute is not cleared when function is optimized to return undef.

rebased and clang format-ed the code, ready to merge

Sep 1 2020, 11:23 AM · Restricted Project, Restricted Project
congzhe added a comment to D86956: [AArch64] Avoid pairing loads when the base reg is modified.

Is it possible to add a MIR test for the issue? Also, it looks like the formatting is off a bit. Could you run clang-format-diff on the change?

Sep 1 2020, 9:59 AM · Restricted Project, Restricted Project, Restricted Project
congzhe added inline comments to D86906: [AArch64] Avoid pairing loads with same result reg.
Sep 1 2020, 9:49 AM · Restricted Project, Restricted Project, Restricted Project
congzhe requested review of D86956: [AArch64] Avoid pairing loads when the base reg is modified.
Sep 1 2020, 9:39 AM · Restricted Project, Restricted Project, Restricted Project

Aug 31 2020

congzhe requested review of D86906: [AArch64] Avoid pairing loads with same result reg.
Aug 31 2020, 9:34 PM · Restricted Project, Restricted Project, Restricted Project

Aug 28 2020

congzhe added a comment to D84220: [IPSCCP] Fix a bug that the "returned" attribute is not cleared when function is optimized to return undef.

@fhahn Thanks for the comments.

Aug 28 2020, 11:57 AM · Restricted Project, Restricted Project
congzhe updated the diff for D84220: [IPSCCP] Fix a bug that the "returned" attribute is not cleared when function is optimized to return undef.
Aug 28 2020, 11:56 AM · Restricted Project, Restricted Project
congzhe updated the diff for D84220: [IPSCCP] Fix a bug that the "returned" attribute is not cleared when function is optimized to return undef.
Aug 28 2020, 11:52 AM · Restricted Project, Restricted Project

Aug 27 2020

congzhe added inline comments to D84220: [IPSCCP] Fix a bug that the "returned" attribute is not cleared when function is optimized to return undef.
Aug 27 2020, 9:22 AM · Restricted Project, Restricted Project

Aug 19 2020

congzhe added a comment to D84220: [IPSCCP] Fix a bug that the "returned" attribute is not cleared when function is optimized to return undef.

@fhahn could you let me know if you have further comments on this revision? Thanks!

Aug 19 2020, 7:02 AM · Restricted Project, Restricted Project

Aug 17 2020

congzhe added inline comments to D84220: [IPSCCP] Fix a bug that the "returned" attribute is not cleared when function is optimized to return undef.
Aug 17 2020, 10:46 AM · Restricted Project, Restricted Project
congzhe updated the diff for D84220: [IPSCCP] Fix a bug that the "returned" attribute is not cleared when function is optimized to return undef.
Aug 17 2020, 10:43 AM · Restricted Project, Restricted Project
congzhe added a comment to D84220: [IPSCCP] Fix a bug that the "returned" attribute is not cleared when function is optimized to return undef.

The assertion doesn't work alone. I would still prefer not to skip over non-call sites blindly. @fhahn in addition to blockaddr users, do we expect anything else? We can skip those just fine.

Thank you, now skipped over blockaddr users.

Looks like the line numbers in my previous comment got messed up. I let them at an earlier version that actually contained the code. It would be good if you could update the patch with a squashed version of all changes.

Thanks for the comment, now squashed all commits into a single one.

Aug 17 2020, 9:51 AM · Restricted Project, Restricted Project

Aug 10 2020

congzhe added a comment to D84220: [IPSCCP] Fix a bug that the "returned" attribute is not cleared when function is optimized to return undef.

The assertion doesn't work alone. I would still prefer not to skip over non-call sites blindly. @fhahn in addition to blockaddr users, do we expect anything else? We can skip those just fine.

Aug 10 2020, 4:58 PM · Restricted Project, Restricted Project
congzhe updated the diff for D84220: [IPSCCP] Fix a bug that the "returned" attribute is not cleared when function is optimized to return undef.

Updated and squashed all commits into a single one

Aug 10 2020, 4:46 PM · Restricted Project, Restricted Project

Aug 7 2020

congzhe added inline comments to D84220: [IPSCCP] Fix a bug that the "returned" attribute is not cleared when function is optimized to return undef.
Aug 7 2020, 8:56 AM · Restricted Project, Restricted Project

Aug 6 2020

congzhe added inline comments to D84220: [IPSCCP] Fix a bug that the "returned" attribute is not cleared when function is optimized to return undef.
Aug 6 2020, 11:10 PM · Restricted Project, Restricted Project
congzhe updated the diff for D84220: [IPSCCP] Fix a bug that the "returned" attribute is not cleared when function is optimized to return undef.

Comments addressed:

Aug 6 2020, 11:09 PM · Restricted Project, Restricted Project
congzhe added inline comments to D84220: [IPSCCP] Fix a bug that the "returned" attribute is not cleared when function is optimized to return undef.
Aug 6 2020, 6:07 PM · Restricted Project, Restricted Project

Aug 5 2020

congzhe added inline comments to D84220: [IPSCCP] Fix a bug that the "returned" attribute is not cleared when function is optimized to return undef.
Aug 5 2020, 8:53 AM · Restricted Project, Restricted Project

Jul 31 2020

congzhe updated the diff for D84220: [IPSCCP] Fix a bug that the "returned" attribute is not cleared when function is optimized to return undef.
Jul 31 2020, 3:43 PM · Restricted Project, Restricted Project
congzhe updated the diff for D84220: [IPSCCP] Fix a bug that the "returned" attribute is not cleared when function is optimized to return undef.

comments addressed:

Jul 31 2020, 9:22 AM · Restricted Project, Restricted Project

Jul 30 2020

congzhe added a comment to D84220: [IPSCCP] Fix a bug that the "returned" attribute is not cleared when function is optimized to return undef.

FWIW, I don't try to block this. The call site attribute comment is not addressed but other than that this patch "makes sense" assuming we keep the current semantics.

Jul 30 2020, 2:23 PM · Restricted Project, Restricted Project
congzhe added a comment to D84220: [IPSCCP] Fix a bug that the "returned" attribute is not cleared when function is optimized to return undef.

I'm not sure I understand the motivation. My problem is that if we replace the return values with undef, it should mean there is no use of the returned value of the function live anymore. What am I missing? Maybe provide the motivating example as a test case?

We use "returned" in codegen even if the value has no uses; see https://reviews.llvm.org/D64986 .

Jul 30 2020, 1:00 PM · Restricted Project, Restricted Project

Jul 29 2020

congzhe added a comment to D84220: [IPSCCP] Fix a bug that the "returned" attribute is not cleared when function is optimized to return undef.

The current definition of "returned" in LangRef is unclear, yes.

In terms of what we actually want, the "must be equal or else instant UB" variation seems more useful than the "must be equal or poison" variation. With "must be equal or poison", basically the only legal optimization is replacing the result with the argument.

I always thought that was the purpose. Could you elaborate what else we want to do?

The only reason I can think of we wouldn't want the instant UB is if it interacts badly with some significant number of optimizations. I'm not coming up with anything it could interact badly with off the top of my head, though, and any transform that did have an issue would also interact badly with noundef.

I agree that it would interact badly with noundef but I was always thinking that would be less of an issue, maybe I'm wrong though.

When it comes to optimizations, I think this shows how problematic the UB semantic is. The codegen interpretation is the problem not IPSCCP (IMHO). Even if you disagree, I doubt this will fix it. Without running it I would suspect https://godbolt.org/z/rG48nz to have at least one returned argument in a ret undef function. @congzhe could you try this?

Jul 29 2020, 1:43 PM · Restricted Project, Restricted Project

Jul 28 2020

congzhe added a comment to D84220: [IPSCCP] Fix a bug that the "returned" attribute is not cleared when function is optimized to return undef.

Florian, can you take a look?

On Tue, Jul 28, 2020 at 10:35 PM Florian Hahn via llvm-commits <llvm-commits@lists.llvm.org> wrote:

On Jul 28, 2020, at 20:32, Congzhe Cao via Phabricator <reviews@reviews.llvm.org> wrote:

congzhe added a comment.

Could you review this patch please? Thank you! @nikic @davide @efriedma

As I mentioned already, I have some comments in phabricator, but cannot submit them because "You do not have permission to edit this object.”

FWIW it is not common to lock down reviews to require Admin permissions.


llvm-commits mailing list
llvm-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-commits

Jul 28 2020, 12:41 PM · Restricted Project, Restricted Project
congzhe changed the edit policy for D84220: [IPSCCP] Fix a bug that the "returned" attribute is not cleared when function is optimized to return undef.
Jul 28 2020, 12:40 PM · Restricted Project, Restricted Project
congzhe added a comment to D84220: [IPSCCP] Fix a bug that the "returned" attribute is not cleared when function is optimized to return undef.

Could you review this patch please? Thank you! @nikic @davide @efriedma

Jul 28 2020, 12:32 PM · Restricted Project, Restricted Project

Jul 25 2020

congzhe added reviewers for D84220: [IPSCCP] Fix a bug that the "returned" attribute is not cleared when function is optimized to return undef: jdoerfert, nikic.
Jul 25 2020, 4:12 PM · Restricted Project, Restricted Project

Jul 20 2020

congzhe changed the edit policy for D84220: [IPSCCP] Fix a bug that the "returned" attribute is not cleared when function is optimized to return undef.
Jul 20 2020, 10:00 PM · Restricted Project, Restricted Project