Page MenuHomePhabricator

wlei (Lei Wang)
Software Engineer at Facebook

Projects

User does not belong to any projects.

User Details

User Since
Sep 14 2020, 11:36 PM (39 w, 2 d)

Recent Activity

Yesterday

wlei added inline comments to D104267: [CSSPGO] Fix an invalid hash table reference issue in the CS preinliner..
Wed, Jun 16, 12:47 PM · Restricted Project
wlei added inline comments to D104267: [CSSPGO] Fix an invalid hash table reference issue in the CS preinliner..
Wed, Jun 16, 12:20 PM · Restricted Project
wlei accepted D104129: [CSSPGO] Report zero-count probe in profile instead of dangling probes..

LGTM, thanks!

Wed, Jun 16, 9:47 AM · Restricted Project
wlei added a comment to D104129: [CSSPGO] Report zero-count probe in profile instead of dangling probes..

Curious why we can remove the moveAndDanglePseudoProbes(don't need the concept of dangling)? My understanding is we treat dangling as unknown, at pass1 we need to pass this information to the profiled binary. An optimized-out probe won't have samples, it will be treated as zero if not marked as dangling.

We now use "missing" to represent dangling which is natural, and "missing" is different from zero. The counts inferencer will reason about counts for missing probes. We will flip the concept of dangling to real dead, and likely make a routine like moveAndKillPseudoProbes.

Wed, Jun 16, 9:46 AM · Restricted Project

Tue, Jun 15

wlei added a comment to D104129: [CSSPGO] Report zero-count probe in profile instead of dangling probes..

Curious why we can remove the moveAndDanglePseudoProbes(don't need the concept of dangling)? My understanding is we treat dangling as unknown, at pass1 we need to pass this information to the profiled binary. An optimized-out probe won't have samples, it will be treated as zero if not marked as dangling.

Tue, Jun 15, 11:57 PM · Restricted Project

Mon, Jun 14

wlei added a comment to D104267: [CSSPGO] Fix an invalid hash table reference issue in the CS preinliner..

Thanks for the fix!

Mon, Jun 14, 9:54 PM · Restricted Project
wlei committed rG863184dd6920: [CSSPGO] Aggregation by the last K context frames for cold profiles (authored by wlei).
[CSSPGO] Aggregation by the last K context frames for cold profiles
Mon, Jun 14, 10:34 AM
wlei closed D104131: [CSSPGO] Aggregation by the last K context frames for cold profiles.
Mon, Jun 14, 10:34 AM · Restricted Project

Fri, Jun 11

wlei updated the diff for D104131: [CSSPGO] Aggregation by the last K context frames for cold profiles.

Addressing Wenlei's comments

Fri, Jun 11, 9:30 PM · Restricted Project
wlei updated the diff for D104131: [CSSPGO] Aggregation by the last K context frames for cold profiles.

change to use uint32_t

Fri, Jun 11, 12:28 PM · Restricted Project
wlei updated the diff for D104131: [CSSPGO] Aggregation by the last K context frames for cold profiles.

Addressing Wenlei's comments

Fri, Jun 11, 12:22 PM · Restricted Project
wlei updated the summary of D104131: [CSSPGO] Aggregation by the last K context frames for cold profiles.
Fri, Jun 11, 10:31 AM · Restricted Project
wlei requested review of D104131: [CSSPGO] Aggregation by the last K context frames for cold profiles.
Fri, Jun 11, 10:13 AM · Restricted Project

Thu, Jun 3

wlei accepted D103650: [CSSPGO][llvm-profgen] Make extended binary the default output format.

Thanks for working on this, LGTM!

Thu, Jun 3, 3:02 PM · Restricted Project

Tue, Jun 1

wlei added inline comments to D103178: [CSSPGO][llvm-profgen] Allow multiple executable load segments..
Tue, Jun 1, 12:36 PM · Restricted Project

Tue, May 25

wlei accepted D103071: [CSSPGO][llvm-profgen] Change default cold threshold for context merging.

LGTM, thanks!

Tue, May 25, 9:48 AM · Restricted Project

Mon, May 24

wlei accepted D102961: [CSSPGO][llvm-profgen] Report samples for untrackable frames..

LGTM, thanks for adding useful debug printer.

Mon, May 24, 10:40 AM · Restricted Project
wlei added inline comments to D102961: [CSSPGO][llvm-profgen] Report samples for untrackable frames..
Mon, May 24, 10:23 AM · Restricted Project

Wed, May 19

wlei committed rG6539a80bc9e8: [CSSPGO] Avoid deleting probe instruction in FoldValueComparisonIntoPredecessors (authored by wlei).
[CSSPGO] Avoid deleting probe instruction in FoldValueComparisonIntoPredecessors
Wed, May 19, 1:40 PM
wlei closed D102721: [CSSPGO] Avoid deleting probe instruction in FoldValueComparisonIntoPredecessors.
Wed, May 19, 1:39 PM · Restricted Project

Tue, May 18

wlei added a comment to D102721: [CSSPGO] Avoid deleting probe instruction in FoldValueComparisonIntoPredecessors.

Thanks for the fix. Is it possible to add a test?

Tue, May 18, 8:02 PM · Restricted Project
wlei updated the diff for D102721: [CSSPGO] Avoid deleting probe instruction in FoldValueComparisonIntoPredecessors.

Address Hongtao's feedback, add test case

Tue, May 18, 8:02 PM · Restricted Project

May 18 2021

wlei updated the summary of D102721: [CSSPGO] Avoid deleting probe instruction in FoldValueComparisonIntoPredecessors.
May 18 2021, 1:32 PM · Restricted Project
wlei requested review of D102721: [CSSPGO] Avoid deleting probe instruction in FoldValueComparisonIntoPredecessors.
May 18 2021, 1:22 PM · Restricted Project

May 14 2021

wlei added a comment to D102429: [CSSPGO] Update pseudo probe distribution factor based on inline context..

Try to understand this:

So we merge the samples from the same function but different context, does this cause the issue?

Exactly.

Such probes should not share samples and their factors should be fixed up separately.

So with that, when code duplication happens, we need to fix probe factor, so here it will do it separately by grouping the probe by different inline context. then each group work for one context inlining. is my understanding correct?

That's right. Probe in a function profile can have multiple copies due to code duplication. We just want to share the corresponding samples among these duplications, but not among all probes with same id but from different function profiles.

May 14 2021, 2:42 PM · Restricted Project
wlei committed rGe475d4d69f04: [CSSPGO] Fix return value of getProbeWeight (authored by wlei).
[CSSPGO] Fix return value of getProbeWeight
May 14 2021, 2:06 PM
wlei closed D102007: [CSSPGO] Fix return value of getProbeWeight.
May 14 2021, 2:06 PM · Restricted Project
wlei added a comment to D102429: [CSSPGO] Update pseudo probe distribution factor based on inline context..

Try to understand this:

May 14 2021, 11:25 AM · Restricted Project

May 11 2021

wlei updated the diff for D102007: [CSSPGO] Fix return value of getProbeWeight.

Update the comments according reviewers' discussion on profile-accurate. Currently, this version only work for probe-based code, it won't be affected by the source drift(see the comments)

May 11 2021, 5:54 PM · Restricted Project

May 6 2021

wlei updated the summary of D102007: [CSSPGO] Fix return value of getProbeWeight.
May 6 2021, 10:35 AM · Restricted Project
wlei updated the diff for D102007: [CSSPGO] Fix return value of getProbeWeight.

update comments

May 6 2021, 10:22 AM · Restricted Project
wlei requested review of D102007: [CSSPGO] Fix return value of getProbeWeight.
May 6 2021, 10:16 AM · Restricted Project

Apr 23 2021

wlei committed rG3d1aecbd2857: [CSSPGO] Fix missing debug info of dangling pseudo probe (authored by wlei).
[CSSPGO] Fix missing debug info of dangling pseudo probe
Apr 23 2021, 2:29 PM
wlei closed D101195: [CSSPGO] Fix missing debug info of dangling pseudo probe.
Apr 23 2021, 2:29 PM · Restricted Project
wlei updated the diff for D101195: [CSSPGO] Fix missing debug info of dangling pseudo probe.

address Hongtao's feedback: refine the test case

Apr 23 2021, 2:14 PM · Restricted Project
wlei added inline comments to D101195: [CSSPGO] Fix missing debug info of dangling pseudo probe.
Apr 23 2021, 1:52 PM · Restricted Project
wlei updated the diff for D101195: [CSSPGO] Fix missing debug info of dangling pseudo probe.

fix assertion condition

Apr 23 2021, 1:52 PM · Restricted Project
wlei added inline comments to D101195: [CSSPGO] Fix missing debug info of dangling pseudo probe.
Apr 23 2021, 1:42 PM · Restricted Project
wlei updated the diff for D101195: [CSSPGO] Fix missing debug info of dangling pseudo probe.

addressing Wenlei's feedback

Apr 23 2021, 1:42 PM · Restricted Project
wlei updated the summary of D101195: [CSSPGO] Fix missing debug info of dangling pseudo probe.
Apr 23 2021, 1:10 PM · Restricted Project
wlei requested review of D101195: [CSSPGO] Fix missing debug info of dangling pseudo probe.
Apr 23 2021, 1:01 PM · Restricted Project

Apr 21 2021

wlei accepted D100235: [CSSPGO][llvm-profgen] Always report dangling probes for frames with real samples..

LGTM, thanks for the fix.

Apr 21 2021, 10:54 AM · Restricted Project

Apr 20 2021

wlei added inline comments to D100235: [CSSPGO][llvm-profgen] Always report dangling probes for frames with real samples..
Apr 20 2021, 11:22 PM · Restricted Project

Apr 5 2021

wlei updated the diff for D99787: [CSSPGO] Fix incorrect probe distribution factor computation in top-down inliner.

switch to explicit cast

Apr 5 2021, 3:23 PM · Restricted Project
wlei updated the diff for D99787: [CSSPGO] Fix incorrect probe distribution factor computation in top-down inliner.

Addressing Hongtao's feedback

Apr 5 2021, 1:47 PM · Restricted Project
wlei updated the diff for D99787: [CSSPGO] Fix incorrect probe distribution factor computation in top-down inliner.

ad test case: manually make a < 1 factor of the promotable call site, after ICP check the discriminator

Apr 5 2021, 10:50 AM · Restricted Project

Apr 2 2021

wlei added inline comments to D99787: [CSSPGO] Fix incorrect probe distribution factor computation in top-down inliner.
Apr 2 2021, 10:22 AM · Restricted Project
wlei added inline comments to D95929: [CSSPGO][llvm-profgen] Add brackets for context id to support extended binary format.
Apr 2 2021, 10:19 AM · Restricted Project
wlei added inline comments to D95929: [CSSPGO][llvm-profgen] Add brackets for context id to support extended binary format.
Apr 2 2021, 10:05 AM · Restricted Project

Apr 1 2021

wlei updated the summary of D99787: [CSSPGO] Fix incorrect probe distribution factor computation in top-down inliner.
Apr 1 2021, 10:54 PM · Restricted Project
wlei accepted D99788: [CSSPGO] Skip dangling probe value when computing profile summary.
Apr 1 2021, 10:47 PM · Restricted Project
wlei added a comment to D99788: [CSSPGO] Skip dangling probe value when computing profile summary.

lgtm, thanks!

Apr 1 2021, 10:46 PM · Restricted Project
wlei requested review of D99787: [CSSPGO] Fix incorrect probe distribution factor computation in top-down inliner.
Apr 1 2021, 10:04 PM · Restricted Project

Mar 23 2021

wlei added a comment to D96787: Make clangd CompletionModel usable even with non-standard (but supported) layout.
Mar 23 2021, 1:13 PM · Restricted Project

Mar 22 2021

wlei accepted D98921: [CSSPGO][llvm-profgen] Use profile summary based threshold for context trimming and merging.

LGTM, thanks!

Mar 22 2021, 8:55 AM · Restricted Project

Mar 21 2021

wlei added inline comments to D98921: [CSSPGO][llvm-profgen] Use profile summary based threshold for context trimming and merging.
Mar 21 2021, 10:30 PM · Restricted Project

Mar 15 2021

wlei committed rGdddd590fd0bc: [CSSPGO][llvm-profgen] Fix getCanonicalFnName usage in llvm-profgen (authored by wlei).
[CSSPGO][llvm-profgen] Fix getCanonicalFnName usage in llvm-profgen
Mar 15 2021, 9:01 PM
wlei closed D98226: [CSSPGO][llvm-profgen] Fix getCanonicalFnName usage in llvm-profgen.
Mar 15 2021, 9:01 PM · Restricted Project
wlei updated the diff for D98226: [CSSPGO][llvm-profgen] Fix getCanonicalFnName usage in llvm-profgen.

Addressing Wei's feedback

Mar 15 2021, 1:55 PM · Restricted Project
wlei added inline comments to D98226: [CSSPGO][llvm-profgen] Fix getCanonicalFnName usage in llvm-profgen.
Mar 15 2021, 1:55 PM · Restricted Project

Mar 13 2021

wlei updated the diff for D98226: [CSSPGO][llvm-profgen] Fix getCanonicalFnName usage in llvm-profgen.

Add test cases

Mar 13 2021, 7:10 PM · Restricted Project

Mar 9 2021

wlei added inline comments to D98226: [CSSPGO][llvm-profgen] Fix getCanonicalFnName usage in llvm-profgen.
Mar 9 2021, 12:14 PM · Restricted Project
wlei added a comment to D98226: [CSSPGO][llvm-profgen] Fix getCanonicalFnName usage in llvm-profgen.

Looks like this is the only place where canonicalization is missing. Would be good to have a test case for proper profile name canonicalization (removing other suffix, but not unique), otherwise looks good.

Mar 9 2021, 10:27 AM · Restricted Project

Mar 8 2021

wlei updated the summary of D98226: [CSSPGO][llvm-profgen] Fix getCanonicalFnName usage in llvm-profgen.
Mar 8 2021, 6:13 PM · Restricted Project
wlei requested review of D98226: [CSSPGO][llvm-profgen] Fix getCanonicalFnName usage in llvm-profgen.
Mar 8 2021, 5:50 PM · Restricted Project
wlei committed rGc460ef61d64f: [CSSPGO][llvm-profgen] Change sample count of dangling probe in llvm-profgen (authored by wlei).
[CSSPGO][llvm-profgen] Change sample count of dangling probe in llvm-profgen
Mar 8 2021, 2:37 PM
wlei closed D96811: [CSSPGO][llvm-profgen] Change sample count of dangling probe in llvm-profgen.
Mar 8 2021, 2:37 PM · Restricted Project

Mar 5 2021

wlei accepted D97998: [CSSPGO] llvm-profdata support for CS profile..

LGTM.

Mar 5 2021, 10:14 AM · Restricted Project

Mar 4 2021

wlei added inline comments to D96811: [CSSPGO][llvm-profgen] Change sample count of dangling probe in llvm-profgen.
Mar 4 2021, 10:13 AM · Restricted Project
wlei updated the diff for D96811: [CSSPGO][llvm-profgen] Change sample count of dangling probe in llvm-profgen.

use merge function to update body samples for probe

Mar 4 2021, 10:07 AM · Restricted Project
wlei added inline comments to D96811: [CSSPGO][llvm-profgen] Change sample count of dangling probe in llvm-profgen.
Mar 4 2021, 12:14 AM · Restricted Project
wlei updated the diff for D96811: [CSSPGO][llvm-profgen] Change sample count of dangling probe in llvm-profgen.

address reviewers' feedback

Mar 4 2021, 12:12 AM · Restricted Project

Mar 3 2021

wlei added inline comments to D96811: [CSSPGO][llvm-profgen] Change sample count of dangling probe in llvm-profgen.
Mar 3 2021, 8:56 PM · Restricted Project
wlei added inline comments to D96811: [CSSPGO][llvm-profgen] Change sample count of dangling probe in llvm-profgen.
Mar 3 2021, 5:46 PM · Restricted Project

Mar 2 2021

wlei added inline comments to D97776: [CSSPGO][llvm-profgen] Continue disassembling after illegal instruction is seen..
Mar 2 2021, 1:10 PM · Restricted Project
wlei accepted D97776: [CSSPGO][llvm-profgen] Continue disassembling after illegal instruction is seen..

Thanks for working on this! LGTM

Mar 2 2021, 12:20 PM · Restricted Project

Feb 17 2021

wlei added inline comments to D96811: [CSSPGO][llvm-profgen] Change sample count of dangling probe in llvm-profgen.
Feb 17 2021, 9:58 AM · Restricted Project
wlei updated the diff for D96811: [CSSPGO][llvm-profgen] Change sample count of dangling probe in llvm-profgen.

remove count towards total sample for dangling probes

Feb 17 2021, 9:58 AM · Restricted Project

Feb 16 2021

wlei added inline comments to D96811: [CSSPGO][llvm-profgen] Change sample count of dangling probe in llvm-profgen.
Feb 16 2021, 10:49 PM · Restricted Project
wlei updated the summary of D96811: [CSSPGO][llvm-profgen] Change sample count of dangling probe in llvm-profgen.
Feb 16 2021, 1:07 PM · Restricted Project
wlei requested review of D96811: [CSSPGO][llvm-profgen] Change sample count of dangling probe in llvm-profgen.
Feb 16 2021, 1:03 PM · Restricted Project

Feb 12 2021

wlei committed rGafd8bd601eaf: [CSSPGO][llvm-profgen] Filter out the instructions without location info for… (authored by wlei).
[CSSPGO][llvm-profgen] Filter out the instructions without location info for…
Feb 12 2021, 4:48 PM
wlei closed D96434: [CSSPGO][llvm-profgen] Filter out the instructions without location info for symbolizer.
Feb 12 2021, 4:48 PM · Restricted Project
wlei committed rG426e326a19fe: [CSSPGO][llvm-profgen] Renovate perfscript check and command line input… (authored by wlei).
[CSSPGO][llvm-profgen] Renovate perfscript check and command line input…
Feb 12 2021, 3:19 PM
wlei closed D96387: [CSSPGO][llvm-profgen] Renovate perfscript check and command line input validation.
Feb 12 2021, 3:19 PM · Restricted Project
wlei updated the summary of D96387: [CSSPGO][llvm-profgen] Renovate perfscript check and command line input validation.
Feb 12 2021, 1:16 PM · Restricted Project
wlei added inline comments to D96387: [CSSPGO][llvm-profgen] Renovate perfscript check and command line input validation.
Feb 12 2021, 12:55 PM · Restricted Project
wlei updated the diff for D96387: [CSSPGO][llvm-profgen] Renovate perfscript check and command line input validation.

change to extern cl::opt<bool> ShowDisassemblyOnly

Feb 12 2021, 12:52 PM · Restricted Project
wlei added inline comments to D96387: [CSSPGO][llvm-profgen] Renovate perfscript check and command line input validation.
Feb 12 2021, 12:35 PM · Restricted Project
wlei updated the diff for D96387: [CSSPGO][llvm-profgen] Renovate perfscript check and command line input validation.

address Wenlei and Hongtao's feedback: switch to use global command line variable and some refactoring work

Feb 12 2021, 12:33 PM · Restricted Project
wlei added inline comments to D96387: [CSSPGO][llvm-profgen] Renovate perfscript check and command line input validation.
Feb 12 2021, 11:59 AM · Restricted Project
wlei updated the diff for D96387: [CSSPGO][llvm-profgen] Renovate perfscript check and command line input validation.

fix clang-tidy

Feb 12 2021, 11:10 AM · Restricted Project
wlei added inline comments to D96387: [CSSPGO][llvm-profgen] Renovate perfscript check and command line input validation.
Feb 12 2021, 11:03 AM · Restricted Project
wlei updated the diff for D96387: [CSSPGO][llvm-profgen] Renovate perfscript check and command line input validation.

address reviewers' feedback:
rename showAssembly to show-disassembly-only and change back to print to stdout

Feb 12 2021, 11:02 AM · Restricted Project
wlei updated the diff for D96434: [CSSPGO][llvm-profgen] Filter out the instructions without location info for symbolizer.

Address Wenlei's feedback and fix lint

Feb 12 2021, 10:32 AM · Restricted Project
wlei added inline comments to D96387: [CSSPGO][llvm-profgen] Renovate perfscript check and command line input validation.
Feb 12 2021, 9:53 AM · Restricted Project
wlei updated the diff for D96387: [CSSPGO][llvm-profgen] Renovate perfscript check and command line input validation.

Address Hongtao's feedback: added test case for invalid script check

Feb 12 2021, 9:37 AM · Restricted Project
wlei added inline comments to D96434: [CSSPGO][llvm-profgen] Filter out the instructions without location info for symbolizer.
Feb 12 2021, 9:34 AM · Restricted Project
wlei updated the diff for D96434: [CSSPGO][llvm-profgen] Filter out the instructions without location info for symbolizer.

address Hongtao's feedback: added comments

Feb 12 2021, 9:25 AM · Restricted Project
wlei committed rGc3aeabaea16e: [CSSPGO][llvm-profgen] Add brackets for context id to support extended binary… (authored by wlei).
[CSSPGO][llvm-profgen] Add brackets for context id to support extended binary…
Feb 12 2021, 1:15 AM