Page MenuHomePhabricator

benshi001 (Ben Shi)
User

Projects

User does not belong to any projects.

User Details

User Since
Jun 6 2020, 5:03 AM (8 w, 4 d)

Recent Activity

Tue, Jul 28

benshi001 added a comment to D83745: [ARM] Optimize immediate selection.

I understood from your message to the llvm dev list that generating numbers isn't entirely straightforward for you.
I will take this patch, and generate some numbers, will see if I can do that today/tomorrow, and will let you know.

Tue, Jul 28, 5:49 AM · Restricted Project
benshi001 added a comment to D83745: [ARM] Optimize immediate selection.

I understood from your message to the llvm dev list that generating numbers isn't entirely straightforward for you.
I will take this patch, and generate some numbers, will see if I can do that today/tomorrow, and will let you know.

Tue, Jul 28, 5:45 AM · Restricted Project

Mon, Jul 27

benshi001 added a comment to D83745: [ARM] Optimize immediate selection.

Eye balling the one test that was changed this indeed makes sense. But I would prefer to see some performance numbers first just to check we haven't missed anything.

Mon, Jul 27, 7:42 AM · Restricted Project
benshi001 added a comment to D83745: [ARM] Optimize immediate selection.

Eye balling the one test that was changed this indeed makes sense. But I would prefer to see some performance numbers first just to check we haven't missed anything.

Mon, Jul 27, 7:38 AM · Restricted Project
benshi001 added a comment to D83928: [ARM][TEST] Add a new test case of add-imm & sub-imm.

Although I don't mind at all new tests being added, in this case I am really wondering if the code paths are not exercised by existing tests. And also reading the description:

This case will show furture optimization of add-imm & sub-imm.

I am wondering what these future optimizations are and if these tests should simply go in with that then?

Mon, Jul 27, 7:19 AM · Restricted Project
benshi001 added a comment to D83745: [ARM] Optimize immediate selection.

ping

Mon, Jul 27, 6:05 AM · Restricted Project
benshi001 added a comment to D83928: [ARM][TEST] Add a new test case of add-imm & sub-imm.

ping

Mon, Jul 27, 6:05 AM · Restricted Project
benshi001 added a comment to D84100: [ARM] Optimize immediate selection.

ping

Mon, Jul 27, 6:05 AM · Restricted Project

Thu, Jul 23

benshi001 abandoned D83153: [DAGCombiner] Prevent regression in isMulAddWithConstProfitable.
Thu, Jul 23, 6:16 PM · Restricted Project

Wed, Jul 22

benshi001 added inline comments to D83153: [DAGCombiner] Prevent regression in isMulAddWithConstProfitable.
Wed, Jul 22, 7:30 PM · Restricted Project
benshi001 added inline comments to D83153: [DAGCombiner] Prevent regression in isMulAddWithConstProfitable.
Wed, Jul 22, 7:18 PM · Restricted Project

Sun, Jul 19

benshi001 updated the diff for D84100: [ARM] Optimize immediate selection.
Sun, Jul 19, 5:59 AM · Restricted Project
benshi001 updated the diff for D83153: [DAGCombiner] Prevent regression in isMulAddWithConstProfitable.
Sun, Jul 19, 5:40 AM · Restricted Project
benshi001 updated the diff for D83745: [ARM] Optimize immediate selection.
Sun, Jul 19, 5:13 AM · Restricted Project
benshi001 updated the diff for D83928: [ARM][TEST] Add a new test case of add-imm & sub-imm.
Sun, Jul 19, 5:07 AM · Restricted Project

Sat, Jul 18

benshi001 added a comment to D84100: [ARM] Optimize immediate selection.

The patch depends on https://reviews.llvm.org/D83928, it will show improvements based on it.

Sat, Jul 18, 7:34 AM · Restricted Project
benshi001 added a comment to D84100: [ARM] Optimize immediate selection.

This patch does two optimization:

Sat, Jul 18, 7:30 AM · Restricted Project
Herald added a project to D84100: [ARM] Optimize immediate selection: Restricted Project.
Sat, Jul 18, 7:24 AM · Restricted Project

Fri, Jul 17

benshi001 added a comment to D83153: [DAGCombiner] Prevent regression in isMulAddWithConstProfitable.

ping

Fri, Jul 17, 4:18 AM · Restricted Project

Thu, Jul 16

benshi001 added reviewers for D83928: [ARM][TEST] Add a new test case of add-imm & sub-imm: greened, anhtuyen, dmgreen.
Thu, Jul 16, 10:21 PM · Restricted Project
benshi001 added a reviewer for D83928: [ARM][TEST] Add a new test case of add-imm & sub-imm: efriedma.
Thu, Jul 16, 10:19 PM · Restricted Project
benshi001 updated the diff for D83928: [ARM][TEST] Add a new test case of add-imm & sub-imm.
Thu, Jul 16, 4:22 PM · Restricted Project

Wed, Jul 15

benshi001 updated the diff for D83928: [ARM][TEST] Add a new test case of add-imm & sub-imm.
Wed, Jul 15, 11:36 PM · Restricted Project
benshi001 added a comment to D83745: [ARM] Optimize immediate selection.

Okay, I had only a quick first look, perhaps multiple uses isn't a problem.
If it's not too much trouble, confirming this with the llvm test-suite would be good.

Wed, Jul 15, 9:16 PM · Restricted Project
benshi001 added a comment to D83745: [ARM] Optimize immediate selection.
Wed, Jul 15, 9:14 PM · Restricted Project
Herald added a project to D83928: [ARM][TEST] Add a new test case of add-imm & sub-imm: Restricted Project.
Wed, Jul 15, 9:12 PM · Restricted Project
benshi001 added a comment to D83745: [ARM] Optimize immediate selection.

for C code

unsigned int f0(unsigned int a)
{
        return a-0x2323;
}
unsigned int f1(unsigned int a) 
{
        return a+0x2323;
}
Wed, Jul 15, 8:01 AM · Restricted Project
benshi001 added a comment to D83745: [ARM] Optimize immediate selection.
  1. Is there a benchmark test suite I can try?
Wed, Jul 15, 7:23 AM · Restricted Project
benshi001 added a comment to D83745: [ARM] Optimize immediate selection.
Wed, Jul 15, 7:13 AM · Restricted Project
benshi001 added a comment to D83745: [ARM] Optimize immediate selection.
Wed, Jul 15, 7:04 AM · Restricted Project

Tue, Jul 14

benshi001 updated the diff for D83745: [ARM] Optimize immediate selection.
Tue, Jul 14, 12:14 AM · Restricted Project
benshi001 updated the diff for D83745: [ARM] Optimize immediate selection.
Tue, Jul 14, 12:04 AM · Restricted Project

Mon, Jul 13

Herald added a project to D83745: [ARM] Optimize immediate selection: Restricted Project.
Mon, Jul 13, 10:34 PM · Restricted Project

Sat, Jul 11

benshi001 added a comment to D83153: [DAGCombiner] Prevent regression in isMulAddWithConstProfitable.
  1. RISCV got improved
Sat, Jul 11, 8:59 AM · Restricted Project
benshi001 added a comment to D83153: [DAGCombiner] Prevent regression in isMulAddWithConstProfitable.

Change list according to all your comments.

Sat, Jul 11, 8:56 AM · Restricted Project
benshi001 updated the diff for D83153: [DAGCombiner] Prevent regression in isMulAddWithConstProfitable.
Sat, Jul 11, 8:49 AM · Restricted Project

Fri, Jul 10

benshi001 updated the diff for D83159: [RISCV][test] Add a new codegen test of add-mul transform.
Fri, Jul 10, 5:38 PM · Restricted Project
benshi001 updated the diff for D83159: [RISCV][test] Add a new codegen test of add-mul transform.
Fri, Jul 10, 4:24 AM · Restricted Project

Tue, Jul 7

benshi001 updated the diff for D82660: [RISCV] Optimize multiplication by constant.
Tue, Jul 7, 6:27 PM · Restricted Project
benshi001 updated the diff for D82262: [RISCV] optimize addition with a pair of (addi imm).
Tue, Jul 7, 6:10 PM · Restricted Project
benshi001 added a comment to D83153: [DAGCombiner] Prevent regression in isMulAddWithConstProfitable.

Change list according to all your comments.

Tue, Jul 7, 5:53 AM · Restricted Project
benshi001 updated the diff for D83153: [DAGCombiner] Prevent regression in isMulAddWithConstProfitable.
Tue, Jul 7, 5:48 AM · Restricted Project

Jul 6 2020

benshi001 added a comment to D83153: [DAGCombiner] Prevent regression in isMulAddWithConstProfitable.

Chnage list according to all your comments.

Jul 6 2020, 2:38 AM · Restricted Project
benshi001 updated the diff for D83153: [DAGCombiner] Prevent regression in isMulAddWithConstProfitable.

One more change:

Jul 6 2020, 2:28 AM · Restricted Project
benshi001 added inline comments to D83153: [DAGCombiner] Prevent regression in isMulAddWithConstProfitable.
Jul 6 2020, 1:15 AM · Restricted Project

Jul 5 2020

benshi001 updated the diff for D82262: [RISCV] optimize addition with a pair of (addi imm).

Thanks. I have improved the function names according to your suggestion!

Jul 5 2020, 5:51 AM · Restricted Project
benshi001 updated the diff for D83153: [DAGCombiner] Prevent regression in isMulAddWithConstProfitable.

Thanks for all of your suggestions. I have uploaded a new patch edition.

Jul 5 2020, 5:19 AM · Restricted Project

Jul 4 2020

benshi001 added inline comments to D83153: [DAGCombiner] Prevent regression in isMulAddWithConstProfitable.
Jul 4 2020, 9:40 AM · Restricted Project
benshi001 added a comment to D83159: [RISCV][test] Add a new codegen test of add-mul transform.

This patch will show the optimization by my previous patch https://reviews.llvm.org/D83153

Jul 4 2020, 9:40 AM · Restricted Project
benshi001 created D83159: [RISCV][test] Add a new codegen test of add-mul transform.
Jul 4 2020, 9:40 AM · Restricted Project
benshi001 added inline comments to D83153: [DAGCombiner] Prevent regression in isMulAddWithConstProfitable.
Jul 4 2020, 9:40 AM · Restricted Project
benshi001 updated the summary of D83153: [DAGCombiner] Prevent regression in isMulAddWithConstProfitable.
Jul 4 2020, 1:33 AM · Restricted Project
benshi001 added a comment to D83153: [DAGCombiner] Prevent regression in isMulAddWithConstProfitable.

The build failure does not related to my changes, today's llvm master branch also has them after running "make check-all"

Jul 4 2020, 1:33 AM · Restricted Project

Jul 3 2020

benshi001 added a comment to D83153: [DAGCombiner] Prevent regression in isMulAddWithConstProfitable.

My patch at least generates better code x86, aarch64 and riscv.

Jul 3 2020, 9:41 PM · Restricted Project
benshi001 created D83153: [DAGCombiner] Prevent regression in isMulAddWithConstProfitable.
Jul 3 2020, 9:37 PM · Restricted Project

Jul 2 2020

benshi001 added a comment to D82660: [RISCV] Optimize multiplication by constant.

I'm happy with this optimisation where this patch removes multiply libcalls.

Where the target has a the m extension, and especially for 64-bit multiplies on rv32im, I'm not sure this is an optimisation.

I think that, for the moment, we should add a guard to the hook to avoid this transformation where we do have mul instructions:

if (Subtarget.hasStdExtM())
  return false;

What do you think?

Jul 2 2020, 9:10 AM · Restricted Project
benshi001 updated the diff for D82660: [RISCV] Optimize multiplication by constant.
Jul 2 2020, 9:10 AM · Restricted Project
benshi001 updated the diff for D82660: [RISCV] Optimize multiplication by constant.
Jul 2 2020, 8:37 AM · Restricted Project

Jul 1 2020

benshi001 added inline comments to D82660: [RISCV] Optimize multiplication by constant.
Jul 1 2020, 8:31 PM · Restricted Project
benshi001 updated the diff for D82660: [RISCV] Optimize multiplication by constant.
Jul 1 2020, 8:31 PM · Restricted Project

Jun 30 2020

benshi001 added a comment to D82262: [RISCV] optimize addition with a pair of (addi imm).

ping ...

Jun 30 2020, 11:15 PM · Restricted Project
benshi001 added a comment to D82262: [RISCV] optimize addition with a pair of (addi imm).

Could you please help me review it? I have not got any suggestion for one week :)

Jun 30 2020, 10:43 PM · Restricted Project

Jun 27 2020

benshi001 added a comment to D82660: [RISCV] Optimize multiplication by constant.

Thanks. I have uploaded a new version according to your suggestion!

Jun 27 2020, 1:53 AM · Restricted Project
benshi001 updated the diff for D82660: [RISCV] Optimize multiplication by constant.
Jun 27 2020, 1:49 AM · Restricted Project

Jun 26 2020

benshi001 updated the summary of D82660: [RISCV] Optimize multiplication by constant.
Jun 26 2020, 8:44 AM · Restricted Project
benshi001 updated the summary of D82660: [RISCV] Optimize multiplication by constant.
Jun 26 2020, 8:44 AM · Restricted Project
benshi001 updated the summary of D82660: [RISCV] Optimize multiplication by constant.
Jun 26 2020, 8:44 AM · Restricted Project
benshi001 updated the summary of D82660: [RISCV] Optimize multiplication by constant.
Jun 26 2020, 8:11 AM · Restricted Project
benshi001 added a reviewer for D82660: [RISCV] Optimize multiplication by constant: kito-cheng.

This patch can not cover all cases (especially "call __mulsi3" on rv32 without M extension), but at least it works well for most cases.

Jun 26 2020, 8:10 AM · Restricted Project
benshi001 created D82660: [RISCV] Optimize multiplication by constant.
Jun 26 2020, 8:10 AM · Restricted Project

Jun 25 2020

benshi001 added a reviewer for D82262: [RISCV] optimize addition with a pair of (addi imm): kito-cheng.
Jun 25 2020, 4:23 PM · Restricted Project
benshi001 added a comment to D82262: [RISCV] optimize addition with a pair of (addi imm).

Why "Harbormaster failed remote builds in B61745: Diff 273379!" ???

Jun 25 2020, 3:51 PM · Restricted Project
benshi001 added a comment to D82262: [RISCV] optimize addition with a pair of (addi imm).

All done. Thanks for your suggestion. ^_^

Jun 25 2020, 8:34 AM · Restricted Project
benshi001 updated the diff for D82262: [RISCV] optimize addition with a pair of (addi imm).
Jun 25 2020, 8:33 AM · Restricted Project

Jun 21 2020

benshi001 updated the diff for D82262: [RISCV] optimize addition with a pair of (addi imm).
Jun 21 2020, 4:13 AM · Restricted Project

Jun 20 2020

benshi001 added reviewers for D82262: [RISCV] optimize addition with a pair of (addi imm): lenary, shiva0217.
Jun 20 2020, 7:36 PM · Restricted Project
benshi001 updated the diff for D82262: [RISCV] optimize addition with a pair of (addi imm).
Jun 20 2020, 6:01 PM · Restricted Project
benshi001 abandoned D82254: [RISCV] Simplify calling use_empty().
Jun 20 2020, 4:57 PM · Restricted Project
benshi001 added a comment to D82262: [RISCV] optimize addition with a pair of (addi imm).

My information,

Jun 20 2020, 10:02 AM · Restricted Project
benshi001 added a comment to D82254: [RISCV] Simplify calling use_empty().

Sorry, it is my mistake. Please close this review request.

Jun 20 2020, 10:02 AM · Restricted Project
benshi001 added a comment to D82262: [RISCV] optimize addition with a pair of (addi imm).

for (add i32 %a, 4094), it can be simplfied to
addi a0, a0, 2047
addi a0, a0, 2047.

Jun 20 2020, 10:02 AM · Restricted Project
benshi001 created D82262: [RISCV] optimize addition with a pair of (addi imm).
Jun 20 2020, 10:02 AM · Restricted Project

Jun 19 2020

benshi001 created D82254: [RISCV] Simplify calling use_empty().
Jun 19 2020, 11:57 PM · Restricted Project

Jun 6 2020

benshi001 created D81333: Fix a typo in RISCVISelLowering.cpp.
Jun 6 2020, 6:23 AM · Restricted Project