Page MenuHomePhabricator

HanKuanChen (Han-Kuan Chen)
User

Projects

User does not belong to any projects.

User Details

User Since
Sep 29 2021, 8:32 PM (76 w, 4 d)

Recent Activity

Feb 3 2023

HanKuanChen committed rGd02b9869b242: [RISCV] Don't use constantpool for floating-point value if the value can be… (authored by HanKuanChen).
[RISCV] Don't use constantpool for floating-point value if the value can be…
Feb 3 2023, 10:42 PM · Restricted Project, Restricted Project
HanKuanChen closed D142953: [RISCV] Don't use constantpool for floating-point value if the value can be easily constructed by integer sequence and a floating-point move..
Feb 3 2023, 10:42 PM · Restricted Project, Restricted Project

Feb 2 2023

HanKuanChen updated the diff for D142953: [RISCV] Don't use constantpool for floating-point value if the value can be easily constructed by integer sequence and a floating-point move..

Apply Philip's comment.

Feb 2 2023, 7:24 PM · Restricted Project, Restricted Project

Jan 31 2023

HanKuanChen updated the diff for D142953: [RISCV] Don't use constantpool for floating-point value if the value can be easily constructed by integer sequence and a floating-point move..

Apply Craig's comment.

Jan 31 2023, 7:46 PM · Restricted Project, Restricted Project

Jan 30 2023

HanKuanChen requested review of D142953: [RISCV] Don't use constantpool for floating-point value if the value can be easily constructed by integer sequence and a floating-point move..
Jan 30 2023, 10:55 PM · Restricted Project, Restricted Project

Nov 22 2022

HanKuanChen committed rGcaa9f63022d2: [CodeGen] Refactor visitSCALAR_TO_VECTOR. NFC. (authored by HanKuanChen).
[CodeGen] Refactor visitSCALAR_TO_VECTOR. NFC.
Nov 22 2022, 1:29 AM · Restricted Project, Restricted Project
HanKuanChen closed D137688: [CodeGen] Refactor visitSCALAR_TO_VECTOR. NFC..
Nov 22 2022, 1:29 AM · Restricted Project, Restricted Project

Nov 17 2022

HanKuanChen committed rG7e6dbfcd9d26: [RISCV] Make lowerVECTOR_SHUFFLEAsVSlidedown follow source until not… (authored by HanKuanChen).
[RISCV] Make lowerVECTOR_SHUFFLEAsVSlidedown follow source until not…
Nov 17 2022, 10:33 PM · Restricted Project, Restricted Project
HanKuanChen committed rG2e58d4bc4b3f: [RISCV] Pre-commit test. (authored by HanKuanChen).
[RISCV] Pre-commit test.
Nov 17 2022, 10:33 PM · Restricted Project, Restricted Project
HanKuanChen closed D138025: [RISCV] Make lowerVECTOR_SHUFFLEAsVSlidedown follow source until not EXTRACT_SUBVECTOR..
Nov 17 2022, 10:33 PM · Restricted Project, Restricted Project
HanKuanChen closed D138024: [RISCV] Pre-commit test..
Nov 17 2022, 10:33 PM · Restricted Project, Restricted Project
HanKuanChen updated the diff for D138025: [RISCV] Make lowerVECTOR_SHUFFLEAsVSlidedown follow source until not EXTRACT_SUBVECTOR..

Apply Craig's comment.

Nov 17 2022, 6:53 PM · Restricted Project, Restricted Project

Nov 15 2022

HanKuanChen committed rGaa47bfa9bcfa: [RISCV] Refactor getDefaultVLOps. NFC. (authored by HanKuanChen).
[RISCV] Refactor getDefaultVLOps. NFC.
Nov 15 2022, 6:12 PM · Restricted Project, Restricted Project
HanKuanChen closed D138003: [RISCV] Refactor getDefaultVLOps. NFC..
Nov 15 2022, 6:12 PM · Restricted Project, Restricted Project
HanKuanChen requested review of D138025: [RISCV] Make lowerVECTOR_SHUFFLEAsVSlidedown follow source until not EXTRACT_SUBVECTOR..
Nov 15 2022, 4:31 AM · Restricted Project, Restricted Project
HanKuanChen updated the summary of D138024: [RISCV] Pre-commit test..
Nov 15 2022, 4:30 AM · Restricted Project, Restricted Project
HanKuanChen updated the diff for D138024: [RISCV] Pre-commit test..

Add reviewers.

Nov 15 2022, 4:30 AM · Restricted Project, Restricted Project
HanKuanChen requested review of D138024: [RISCV] Pre-commit test..
Nov 15 2022, 4:28 AM · Restricted Project, Restricted Project
HanKuanChen updated the diff for D137688: [CodeGen] Refactor visitSCALAR_TO_VECTOR. NFC..

Apply spatel's comment.

Nov 15 2022, 12:02 AM · Restricted Project, Restricted Project

Nov 14 2022

HanKuanChen updated the diff for D138003: [RISCV] Refactor getDefaultVLOps. NFC..

Fix getDefaultVLOps name and implementation.

Nov 14 2022, 10:22 PM · Restricted Project, Restricted Project
HanKuanChen requested review of D138003: [RISCV] Refactor getDefaultVLOps. NFC..
Nov 14 2022, 10:06 PM · Restricted Project, Restricted Project
HanKuanChen updated the diff for D137704: [RISCV] Make lowerVECTOR_SHUFFLEAsVNSRL support more vnsrl shuffle pattern..

Fix vector_shuffle source may be extract_subvector and undef.

Nov 14 2022, 12:40 AM · Restricted Project, Restricted Project

Nov 13 2022

HanKuanChen added a comment to D137704: [RISCV] Make lowerVECTOR_SHUFFLEAsVNSRL support more vnsrl shuffle pattern..

This test crashes

define void @vnsrl_2_undef_float(ptr %in, ptr %out) {
entry:
  %0 = load <32 x float>, ptr %in, align 4
  %1 = shufflevector <32 x float> %0, <32 x float> poison, <16 x i32> <i32 1, i32 3, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef>
  store <16 x float> %1, ptr %out, align 4
  ret void
}

I will merge and close https://reviews.llvm.org/D137904 to solve this test.

How does D137904 solve this? That patch is marked NFC

t7: v32f32,ch = load<(load (s1024) from %ir.in, align 4)> t0, t2, undef:i64
t9: v16f32 = extract_subvector t7, Constant:i64<0>
t11: v16f32 = vector_shuffle<1,3,u,u,u,u,u,u,u,u,u,u,u,u,u,u> t9, undef:v16f32

I expect we use getSingleShuffleSource to get t7 instead of t9. Then we check whether the type of source and destination can match vnsrl rule.
This test has a 2 Difference, and source is v32f32 and destination is v16f32, which is valid.

I don't think that will fix it. The same test crashes if you change the shuffle mask to <i32 1, i32 3, i32 5, i32 7, i32 9, i32 11, i32 13, i32 15>. That cases should have two extract_subvectors.

May you provide the test?
I try <16 x i32> <i32 1, i32 3, i32 5, i32 7, i32 9, i32 11, i32 13, i32 15, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef> and <8 x i32> <i32 1, i32 3, i32 5, i32 7, i32 9, i32 11, i32 13, i32 15>, but I don't get the crash if getSingleShuffleSource is used (and check the source and destination type).

I was using Zvl128b not Zvl256b. Does that make a difference?

Nov 13 2022, 11:45 PM · Restricted Project, Restricted Project
HanKuanChen added a comment to D137704: [RISCV] Make lowerVECTOR_SHUFFLEAsVNSRL support more vnsrl shuffle pattern..

This test crashes

define void @vnsrl_2_undef_float(ptr %in, ptr %out) {
entry:
  %0 = load <32 x float>, ptr %in, align 4
  %1 = shufflevector <32 x float> %0, <32 x float> poison, <16 x i32> <i32 1, i32 3, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef>
  store <16 x float> %1, ptr %out, align 4
  ret void
}

I will merge and close https://reviews.llvm.org/D137904 to solve this test.

How does D137904 solve this? That patch is marked NFC

t7: v32f32,ch = load<(load (s1024) from %ir.in, align 4)> t0, t2, undef:i64
t9: v16f32 = extract_subvector t7, Constant:i64<0>
t11: v16f32 = vector_shuffle<1,3,u,u,u,u,u,u,u,u,u,u,u,u,u,u> t9, undef:v16f32

I expect we use getSingleShuffleSource to get t7 instead of t9. Then we check whether the type of source and destination can match vnsrl rule.
This test has a 2 Difference, and source is v32f32 and destination is v16f32, which is valid.

I don't think that will fix it. The same test crashes if you change the shuffle mask to <i32 1, i32 3, i32 5, i32 7, i32 9, i32 11, i32 13, i32 15>. That cases should have two extract_subvectors.

Nov 13 2022, 11:21 PM · Restricted Project, Restricted Project
HanKuanChen added a comment to D137704: [RISCV] Make lowerVECTOR_SHUFFLEAsVNSRL support more vnsrl shuffle pattern..

Am I correct in thinking that all of the tests are using LMUL=1 or fractional LMUL?

Nov 13 2022, 11:03 PM · Restricted Project, Restricted Project
HanKuanChen added a comment to D137704: [RISCV] Make lowerVECTOR_SHUFFLEAsVNSRL support more vnsrl shuffle pattern..

This test crashes

define void @vnsrl_2_undef_float(ptr %in, ptr %out) {
entry:
  %0 = load <32 x float>, ptr %in, align 4
  %1 = shufflevector <32 x float> %0, <32 x float> poison, <16 x i32> <i32 1, i32 3, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef>
  store <16 x float> %1, ptr %out, align 4
  ret void
}

I will merge and close https://reviews.llvm.org/D137904 to solve this test.

How does D137904 solve this? That patch is marked NFC

Nov 13 2022, 10:50 PM · Restricted Project, Restricted Project
HanKuanChen added a comment to D137704: [RISCV] Make lowerVECTOR_SHUFFLEAsVNSRL support more vnsrl shuffle pattern..

This test crashes

define void @vnsrl_2_undef_float(ptr %in, ptr %out) {
entry:
  %0 = load <32 x float>, ptr %in, align 4
  %1 = shufflevector <32 x float> %0, <32 x float> poison, <16 x i32> <i32 1, i32 3, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef>
  store <16 x float> %1, ptr %out, align 4
  ret void
}
Nov 13 2022, 10:14 PM · Restricted Project, Restricted Project
HanKuanChen added inline comments to D137704: [RISCV] Make lowerVECTOR_SHUFFLEAsVNSRL support more vnsrl shuffle pattern..
Nov 13 2022, 9:09 PM · Restricted Project, Restricted Project
HanKuanChen added inline comments to D137904: [RISCV] Provide a isOneSourceVECTOR_SHUFFLE function. NFC..
Nov 13 2022, 8:34 PM · Restricted Project, Restricted Project
HanKuanChen added inline comments to D137704: [RISCV] Make lowerVECTOR_SHUFFLEAsVNSRL support more vnsrl shuffle pattern..
Nov 13 2022, 8:22 PM · Restricted Project, Restricted Project
HanKuanChen requested review of D137904: [RISCV] Provide a isOneSourceVECTOR_SHUFFLE function. NFC..
Nov 13 2022, 12:38 AM · Restricted Project, Restricted Project

Nov 12 2022

HanKuanChen updated the diff for D137704: [RISCV] Make lowerVECTOR_SHUFFLEAsVNSRL support more vnsrl shuffle pattern..

Apply Craig's comment.

Nov 12 2022, 10:42 PM · Restricted Project, Restricted Project

Nov 10 2022

HanKuanChen added inline comments to D137704: [RISCV] Make lowerVECTOR_SHUFFLEAsVNSRL support more vnsrl shuffle pattern..
Nov 10 2022, 10:26 PM · Restricted Project, Restricted Project

Nov 9 2022

HanKuanChen updated the diff for D137704: [RISCV] Make lowerVECTOR_SHUFFLEAsVNSRL support more vnsrl shuffle pattern..

Fix pre-merge checks.

Nov 9 2022, 2:39 AM · Restricted Project, Restricted Project
HanKuanChen requested review of D137704: [RISCV] Make lowerVECTOR_SHUFFLEAsVNSRL support more vnsrl shuffle pattern..
Nov 9 2022, 2:16 AM · Restricted Project, Restricted Project
HanKuanChen requested review of D137703: [RISCV] Pre-commit test..
Nov 9 2022, 2:15 AM · Restricted Project, Restricted Project

Nov 8 2022

HanKuanChen requested review of D137688: [CodeGen] Refactor visitSCALAR_TO_VECTOR. NFC..
Nov 8 2022, 7:27 PM · Restricted Project, Restricted Project
HanKuanChen added inline comments to D137635: [CodeGen] Add sources to isVectorClearMaskLegal. NFC..
Nov 8 2022, 8:48 AM · Restricted Project, Restricted Project
HanKuanChen added a comment to D137635: [CodeGen] Add sources to isVectorClearMaskLegal. NFC..

Do you have an upstream target that actually requires this?

Nov 8 2022, 6:18 AM · Restricted Project, Restricted Project
HanKuanChen requested review of D137635: [CodeGen] Add sources to isVectorClearMaskLegal. NFC..
Nov 8 2022, 5:21 AM · Restricted Project, Restricted Project

Nov 7 2022

HanKuanChen requested review of D137610: [CodeGen] Refactor ExpandBVWithShuffles. NFC..
Nov 7 2022, 10:37 PM · Restricted Project, Restricted Project

Oct 18 2022

HanKuanChen committed rG8d0246a9269b: [RISCV] Pre-commit tests for lowering VECTOR_SHUFFLE to VSLIDEDOWN_VL. (authored by HanKuanChen).
[RISCV] Pre-commit tests for lowering VECTOR_SHUFFLE to VSLIDEDOWN_VL.
Oct 18 2022, 8:59 AM · Restricted Project, Restricted Project
HanKuanChen committed rG615af94dc20c: [RISCV] Lower VECTOR_SHUFFLE to VSLIDEDOWN_VL. (authored by HanKuanChen).
[RISCV] Lower VECTOR_SHUFFLE to VSLIDEDOWN_VL.
Oct 18 2022, 8:59 AM · Restricted Project, Restricted Project
HanKuanChen closed D136136: [RISCV] Lower VECTOR_SHUFFLE to VSLIDEDOWN_VL..
Oct 18 2022, 8:58 AM · Restricted Project, Restricted Project
HanKuanChen closed D136135: [RISCV] Pre-commit tests for lowering VECTOR_SHUFFLE to VSLIDEDOWN_VL..
Oct 18 2022, 8:58 AM · Restricted Project, Restricted Project
HanKuanChen updated the diff for D136136: [RISCV] Lower VECTOR_SHUFFLE to VSLIDEDOWN_VL..

Apply Craig's comments.

Oct 18 2022, 12:44 AM · Restricted Project, Restricted Project

Oct 17 2022

HanKuanChen requested review of D136136: [RISCV] Lower VECTOR_SHUFFLE to VSLIDEDOWN_VL..
Oct 17 2022, 11:54 PM · Restricted Project, Restricted Project
HanKuanChen added a reviewer for D136135: [RISCV] Pre-commit tests for lowering VECTOR_SHUFFLE to VSLIDEDOWN_VL.: craig.topper.
Oct 17 2022, 11:53 PM · Restricted Project, Restricted Project
HanKuanChen updated the diff for D136135: [RISCV] Pre-commit tests for lowering VECTOR_SHUFFLE to VSLIDEDOWN_VL..

Contain pre-commit test only.

Oct 17 2022, 11:52 PM · Restricted Project, Restricted Project
HanKuanChen requested review of D136135: [RISCV] Pre-commit tests for lowering VECTOR_SHUFFLE to VSLIDEDOWN_VL..
Oct 17 2022, 11:50 PM · Restricted Project, Restricted Project

Sep 27 2022

HanKuanChen committed rGc595c874cb32: [RISCV] Lower BUILD_VECTOR to RISCVISD::VID_VL if it is floating-point type. (authored by HanKuanChen).
[RISCV] Lower BUILD_VECTOR to RISCVISD::VID_VL if it is floating-point type.
Sep 27 2022, 5:26 PM · Restricted Project, Restricted Project
HanKuanChen closed D133688: [RISCV] Lower BUILD_VECTOR to RISCVISD::VID_VL if it is floating-point type..
Sep 27 2022, 5:26 PM · Restricted Project, Restricted Project
HanKuanChen updated the diff for D133688: [RISCV] Lower BUILD_VECTOR to RISCVISD::VID_VL if it is floating-point type..
  1. Fix Invalid rounding mode found.
  2. Refactor and add getExactInteger.
Sep 27 2022, 2:14 AM · Restricted Project, Restricted Project

Sep 21 2022

HanKuanChen added a comment to D134400: [RISCV] Improve support for vector fp_to_sint_sat/uint_sat..

LGTM

Sep 21 2022, 9:21 PM · Restricted Project, Restricted Project
HanKuanChen added inline comments to D134400: [RISCV] Improve support for vector fp_to_sint_sat/uint_sat..
Sep 21 2022, 8:53 PM · Restricted Project, Restricted Project

Sep 13 2022

HanKuanChen committed rGdd53a0bb3041: [RISCV] Lower BUILD_VECTOR to RISCVISD::VID_VL if it is floating-point type. (authored by HanKuanChen).
[RISCV] Lower BUILD_VECTOR to RISCVISD::VID_VL if it is floating-point type.
Sep 13 2022, 6:50 PM · Restricted Project, Restricted Project
HanKuanChen closed D133688: [RISCV] Lower BUILD_VECTOR to RISCVISD::VID_VL if it is floating-point type..
Sep 13 2022, 6:50 PM · Restricted Project, Restricted Project

Sep 12 2022

HanKuanChen updated the diff for D133688: [RISCV] Lower BUILD_VECTOR to RISCVISD::VID_VL if it is floating-point type..

Add tests for -0.0 behavior.

Sep 12 2022, 8:44 PM · Restricted Project, Restricted Project
HanKuanChen added a comment to D133688: [RISCV] Lower BUILD_VECTOR to RISCVISD::VID_VL if it is floating-point type..

Does this create -0.0 when it is supposed to?

Sep 12 2022, 8:13 PM · Restricted Project, Restricted Project
HanKuanChen updated the diff for D133688: [RISCV] Lower BUILD_VECTOR to RISCVISD::VID_VL if it is floating-point type..
  1. Rename vle_vid-vfwcvt.ll to vle_vid-vfcvt.ll.
Sep 12 2022, 8:11 PM · Restricted Project, Restricted Project
HanKuanChen added a comment to D133688: [RISCV] Lower BUILD_VECTOR to RISCVISD::VID_VL if it is floating-point type..

Does this create -0.0 when it is supposed to?

Sep 12 2022, 7:31 PM · Restricted Project, Restricted Project
HanKuanChen requested review of D133688: [RISCV] Lower BUILD_VECTOR to RISCVISD::VID_VL if it is floating-point type..
Sep 12 2022, 5:51 AM · Restricted Project, Restricted Project

Jul 1 2022

HanKuanChen added a comment to D124159: [SimplifyCFG] Thread branches on same condition in more cases (PR54980).

HI, the following code get infinite loop after this commit.

Jul 1 2022, 12:51 AM · Restricted Project, Restricted Project, Restricted Project

Jun 17 2022

HanKuanChen committed rGe29133629b3d: [MachineCopyPropagation][RISCV] Fix D125335 accidentally change control flow. (authored by HanKuanChen).
[MachineCopyPropagation][RISCV] Fix D125335 accidentally change control flow.
Jun 17 2022, 9:41 PM · Restricted Project, Restricted Project
HanKuanChen committed rGdbfb00a9300e: [MachineCopyPropagation][RISCV] Add test case showing failure for… (authored by HanKuanChen).
[MachineCopyPropagation][RISCV] Add test case showing failure for…
Jun 17 2022, 9:41 PM · Restricted Project, Restricted Project
HanKuanChen closed D128039: [MachineCopyPropagation] Fix D125335 accidentally change control flow..
Jun 17 2022, 9:40 PM · Restricted Project, Restricted Project
HanKuanChen closed D128040: Add test case showing failure for MachineCopyPropagation. NFC.
Jun 17 2022, 9:40 PM · Restricted Project, Restricted Project
HanKuanChen accepted D128040: Add test case showing failure for MachineCopyPropagation. NFC.

https://reviews.llvm.org/D128039 is accepted.

Jun 17 2022, 9:40 PM · Restricted Project, Restricted Project
HanKuanChen added inline comments to D128039: [MachineCopyPropagation] Fix D125335 accidentally change control flow..
Jun 17 2022, 8:42 AM · Restricted Project, Restricted Project
HanKuanChen updated the diff for D128039: [MachineCopyPropagation] Fix D125335 accidentally change control flow..

Update test.

Jun 17 2022, 3:14 AM · Restricted Project, Restricted Project
HanKuanChen updated the diff for D128040: Add test case showing failure for MachineCopyPropagation. NFC.

Update test.

Jun 17 2022, 3:13 AM · Restricted Project, Restricted Project
HanKuanChen updated the diff for D128039: [MachineCopyPropagation] Fix D125335 accidentally change control flow..

Add tag and more information in commit message.

Jun 17 2022, 2:52 AM · Restricted Project, Restricted Project
HanKuanChen updated the diff for D128040: Add test case showing failure for MachineCopyPropagation. NFC.

Add tag in commit message.

Jun 17 2022, 2:45 AM · Restricted Project, Restricted Project
HanKuanChen requested review of D128040: Add test case showing failure for MachineCopyPropagation. NFC.
Jun 17 2022, 2:35 AM · Restricted Project, Restricted Project
HanKuanChen requested review of D128039: [MachineCopyPropagation] Fix D125335 accidentally change control flow..
Jun 17 2022, 2:34 AM · Restricted Project, Restricted Project

May 5 2022

HanKuanChen requested review of D125067: [RISCV] Add RISCVISD::FCLASS_VL..
May 5 2022, 7:49 PM · Restricted Project, Restricted Project

Mar 9 2022

HanKuanChen commandeered D121087: [RISCV][RVV] Add Uses = [FRM] and mayRaiseFPException = true to RVV instructions.

VFRSQRT7 do not use FRM.
From v-spec,

The output value is independent of the dynamic rounding mode.

Mar 9 2022, 2:08 AM · Restricted Project, Restricted Project

Jan 17 2022

HanKuanChen added reviewers for D117533: [RISCV] Combine (vmv.s.x a, (vmv.x.s b)) to nothing.: craig.topper, frasercrmck.
Jan 17 2022, 9:04 PM · Restricted Project
HanKuanChen requested review of D117533: [RISCV] Combine (vmv.s.x a, (vmv.x.s b)) to nothing..
Jan 17 2022, 9:04 PM · Restricted Project
HanKuanChen updated the diff for D117452: [RISCV] Provide VLOperand in td..

apply sentence advise

Jan 17 2022, 3:27 AM · Restricted Project

Jan 16 2022

HanKuanChen updated the diff for D117452: [RISCV] Provide VLOperand in td..

Apply grammar fix: is not exist -> does not exist

Jan 16 2022, 11:29 PM · Restricted Project
HanKuanChen added reviewers for D117453: [RISCV] Make SplatOperand start from 0.: craig.topper, frasercrmck.
Jan 16 2022, 11:13 PM · Restricted Project
HanKuanChen requested review of D117453: [RISCV] Make SplatOperand start from 0..
Jan 16 2022, 11:10 PM · Restricted Project
HanKuanChen requested review of D117452: [RISCV] Provide VLOperand in td..
Jan 16 2022, 10:50 PM · Restricted Project