Page MenuHomePhabricator

davidxl (David Li)
User

Projects

User does not belong to any projects.

User Details

User Since
Apr 13 2015, 9:48 AM (219 w, 1 d)

Recent Activity

Yesterday

davidxl added a comment to D59225: [profile] Support for GCDA profiling in Fuchsia.

The refactoring part looks ok. +vsk to double check.

Mon, Jun 24, 10:08 AM · Restricted Project, Restricted Project
davidxl added a reviewer for D59225: [profile] Support for GCDA profiling in Fuchsia: vsk.
Mon, Jun 24, 10:07 AM · Restricted Project, Restricted Project

Fri, Jun 21

davidxl added a reviewer for D63671: [llvm-profdata] Avoid keeping reference to every files: wmi.
Fri, Jun 21, 2:14 PM · Restricted Project
davidxl added a comment to D63626: [clang][NewPM] Remove exception handling before loading pgo sample profile data.

Is there a bug reference somewhere?

Fri, Jun 21, 7:33 AM · Restricted Project, Restricted Project

Thu, Jun 13

davidxl accepted D63232: [Coverage] Load code coverage data from archives.

lgtm

Thu, Jun 13, 1:18 PM · Restricted Project
davidxl added a comment to D63232: [Coverage] Load code coverage data from archives.

llvm-cov's user manual probably also needs some update.

Thu, Jun 13, 11:32 AM · Restricted Project
davidxl added a comment to D63232: [Coverage] Load code coverage data from archives.

is thin archive supported?

Thu, Jun 13, 11:26 AM · Restricted Project

Tue, Jun 11

davidxl edited reviewers for D63161: Devirtualize destructor of final class., added: rsmith; removed: davidxl.
Tue, Jun 11, 1:22 PM · Restricted Project, Restricted Project

Mon, Jun 10

davidxl accepted D62700: [PGO] Handle cases of non-instrument BBs.

lgtm

Mon, Jun 10, 2:58 PM · Restricted Project
davidxl added a comment to D62700: [PGO] Handle cases of non-instrument BBs.

This can be handled this way:

Mon, Jun 10, 2:05 PM · Restricted Project
davidxl accepted D43256: [MBP] Move a latch block with conditional exit and multi predecessors to top of loop.

Warning. With static profiling, the layout strategy based on the 'precise' cost model may be off. If for some reason this causes issues later, the change should be guarded with 'hasProfile' check.

Mon, Jun 10, 11:06 AM · Restricted Project
davidxl added inline comments to D62700: [PGO] Handle cases of non-instrument BBs.
Mon, Jun 10, 9:51 AM · Restricted Project
davidxl added inline comments to D62700: [PGO] Handle cases of non-instrument BBs.
Mon, Jun 10, 9:33 AM · Restricted Project

Fri, Jun 7

davidxl added inline comments to D62700: [PGO] Handle cases of non-instrument BBs.
Fri, Jun 7, 10:25 AM · Restricted Project

Thu, Jun 6

davidxl added inline comments to D62700: [PGO] Handle cases of non-instrument BBs.
Thu, Jun 6, 11:14 AM · Restricted Project
davidxl committed rG758c08921da7: [Profile]: Add runtime interface to specify file handle for profile data (Part… (authored by davidxl).
[Profile]: Add runtime interface to specify file handle for profile data (Part…
Thu, Jun 6, 9:27 AM
davidxl committed rL362716: [Profile]: Add runtime interface to specify file handle for profile data (Part….
[Profile]: Add runtime interface to specify file handle for profile data (Part…
Thu, Jun 6, 9:26 AM

Wed, Jun 5

davidxl committed rGc1867557d93d: [Profile]: Add runtime interface to specify file handle for profile data. (authored by davidxl).
[Profile]: Add runtime interface to specify file handle for profile data.
Wed, Jun 5, 11:33 PM
davidxl committed rL362676: [Profile]: Add runtime interface to specify file handle for profile data..
[Profile]: Add runtime interface to specify file handle for profile data.
Wed, Jun 5, 11:32 PM
davidxl closed D62541: Adding a function for setting coverage output file..
Wed, Jun 5, 11:32 PM · Restricted Project, Restricted Project
davidxl added a comment to D62541: Adding a function for setting coverage output file..

It is just more convenient for you to contribute to LLVM in the future. I can help you commit this time.

Wed, Jun 5, 4:27 PM · Restricted Project, Restricted Project
davidxl added a comment to D62541: Adding a function for setting coverage output file..

I suggest you apply for commit right first. There are likely fallouts that need to be dealt with.

Wed, Jun 5, 2:21 PM · Restricted Project, Restricted Project
davidxl accepted D62541: Adding a function for setting coverage output file..

lgtm. Watch out for problems on other platforms.

Wed, Jun 5, 9:49 AM · Restricted Project, Restricted Project

Tue, Jun 4

davidxl added inline comments to D62541: Adding a function for setting coverage output file..
Tue, Jun 4, 2:13 PM · Restricted Project, Restricted Project

Mon, Jun 3

davidxl accepted D62656: Make SwitchInstProfUpdateWrapper safer.

lgtm assuming the state tracking code gets removed (or put under NDEBUG in some way) after the cleanup.

Mon, Jun 3, 8:59 AM · Restricted Project

Fri, May 31

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

For all the test cases update, please also validate if they make sense or not if possible.

Fri, May 31, 2:08 PM · Restricted Project
davidxl added a comment to D62656: Make SwitchInstProfUpdateWrapper safer.

once the cleanup is done, the state tracking should be removed as well.

Fri, May 31, 12:39 PM · Restricted Project

Thu, May 30

davidxl added a comment to D62656: Make SwitchInstProfUpdateWrapper safer.

I suggest the following path:

  1. add an option to enforce internal error on inconsistency; by default the inconsistency is ignored.
  2. fix the exposed root cause one by one
  3. turn on the option by default
Thu, May 30, 11:41 PM · Restricted Project
davidxl added a comment to D62541: Adding a function for setting coverage output file..

Sounds reasonable -- the intention is clear with this -- the interface tells runtime to do whatever needed to ensure merging. Please send a patch with merging test case.

Thu, May 30, 3:36 PM · Restricted Project, Restricted Project
davidxl added inline comments to D62700: [PGO] Handle cases of non-instrument BBs.
Thu, May 30, 2:02 PM · Restricted Project
davidxl added a comment to D62656: Make SwitchInstProfUpdateWrapper safer.

What I meant is that we should never see inconsistent state and instead of setting invalid state, we assert there. Ideally, the profile setting/update APIs should help user avoid creating the inconsistent state in the first place (i.e., catch the problem on the spot).

Thu, May 30, 11:21 AM · Restricted Project
davidxl added inline comments to D62656: Make SwitchInstProfUpdateWrapper safer.
Thu, May 30, 10:59 AM · Restricted Project

Wed, May 29

davidxl added inline comments to D62541: Adding a function for setting coverage output file..
Wed, May 29, 5:08 PM · Restricted Project, Restricted Project
davidxl added a comment to D62541: Adding a function for setting coverage output file..

I think it is cleaner for user to make the intention clear by passing the flag if the file handle is passed to the runtime. Otherwise the runtime will have to guess/assume user's intention (e.g, also reopen the file with "r+b" mode for merging).

Wed, May 29, 4:43 PM · Restricted Project, Restricted Project
davidxl added a comment to D62541: Adding a function for setting coverage output file..

To support merging, the new interface needs to take more

Wed, May 29, 3:31 PM · Restricted Project, Restricted Project

Tue, May 28

davidxl added a comment to D62540: [SampleFDO] For functions without profiles, provide an option to put them in a special text section.

Why is symbol remapping an issue? old MD5 --> input symbol name -> output symbol name --> mapped MD5sum ?

Tue, May 28, 3:46 PM · Restricted Project
davidxl added a comment to D62540: [SampleFDO] For functions without profiles, provide an option to put them in a special text section.

what is the main blocker for the longer term solution?

Tue, May 28, 3:07 PM · Restricted Project
davidxl added a comment to D62540: [SampleFDO] For functions without profiles, provide an option to put them in a special text section.

Longer term, the plan is to put a white list of the symbols into the profile data so that the compiler can decide if a function is newly created or simply cold.

Tue, May 28, 2:34 PM · Restricted Project
davidxl added a comment to D62541: Adding a function for setting coverage output file..

There should be a test case.

Tue, May 28, 1:28 PM · Restricted Project, Restricted Project
davidxl accepted D62439: PGO] Handle cases of failing to split critical edges.

lgtm

Tue, May 28, 11:07 AM · Restricted Project
davidxl added inline comments to D62439: PGO] Handle cases of failing to split critical edges.
Tue, May 28, 10:09 AM · Restricted Project

Mon, May 27

davidxl added inline comments to D62439: PGO] Handle cases of failing to split critical edges.
Mon, May 27, 6:01 PM · Restricted Project

May 24 2019

davidxl added inline comments to D43256: [MBP] Move a latch block with conditional exit and multi predecessors to top of loop.
May 24 2019, 4:21 PM · Restricted Project
davidxl added a comment to D62079: [MBP] Rotate should bring more fallthrough.

Does this patch handle the case in D62079? If yes, you can move the tests added in that patch here.

May 24 2019, 9:39 AM · Restricted Project

May 23 2019

davidxl accepted D62122: [NFC] Introduce SwitchInst wrapper for prof branch_weights handling.

lgtm

May 23 2019, 4:41 PM · Restricted Project

May 22 2019

davidxl accepted D62262: [PGO][CHR] Speed up following long use-def chains..

Indeed. The original one is O(N^2). LGTM.

May 22 2019, 11:31 AM · Restricted Project
davidxl added a comment to D62262: [PGO][CHR] Speed up following long use-def chains..

was there a quadratic behavior before ? It seems linear before and after the patch -- but just cut the computation by a factor of 2 . Do you need an option to control the max chain length?

May 22 2019, 10:14 AM · Restricted Project

May 21 2019

davidxl added inline comments to D61540: [PGO] Use sum of count values to fix func entry count and add a check to verify BFI counts.
May 21 2019, 4:34 PM · Restricted Project
davidxl added a comment to D62079: [MBP] Rotate should bring more fallthrough.

Loop rotation not only affects fall through placement of incoming and exit edges, but internal fall through as well -- it converts the original backedge into a new fallthrough while converts an original internal fallthrough into the backedge. In other words, the overall cost/benefit needs to consider all changes. Doing pattern matching like this can lead to wrong decisions.

May 21 2019, 10:39 AM · Restricted Project
davidxl added inline comments to D62122: [NFC] Introduce SwitchInst wrapper for prof branch_weights handling.
May 21 2019, 9:27 AM · Restricted Project

May 20 2019

davidxl added a comment to D62079: [MBP] Rotate should bring more fallthrough.

I like the direction this patch is going, but I think it can do better.

May 20 2019, 3:58 PM · Restricted Project
davidxl added inline comments to D61540: [PGO] Use sum of count values to fix func entry count and add a check to verify BFI counts.
May 20 2019, 1:47 PM · Restricted Project
davidxl accepted D62078: This change adds an API to allow setting the flag to indicate that the profile data has been dumped to the file..

lgtm

May 20 2019, 12:15 PM · Restricted Project, Restricted Project
davidxl added inline comments to D62123: [NFC] SimplifyCFG prof branch_weighs handling is simplified.
May 20 2019, 12:05 PM · Restricted Project

May 15 2019

davidxl accepted D61932: Fix prof branch_weights in entry_counts_missing_dbginfo.ll test.

lgtm

May 15 2019, 8:41 AM · Restricted Project

May 14 2019

davidxl accepted D61920: [JumpThreading] A bug fix for stale loop info after unfold select.

lgtm

May 14 2019, 3:28 PM · Restricted Project

May 10 2019

davidxl accepted D61789: Skip over prefetches.

lgtm

May 10 2019, 1:43 PM · Restricted Project
davidxl added a comment to D61789: Skip over prefetches.

it is probably better to put the tests in the same file with different check prefixes.

May 10 2019, 1:15 PM · Restricted Project
davidxl added inline comments to D61789: Skip over prefetches.
May 10 2019, 8:46 AM · Restricted Project

May 9 2019

davidxl accepted D61735: [llvm] X86DiscriminateMemOps: insert debug info when missing.

lgtm

May 9 2019, 4:53 PM · Restricted Project
davidxl added inline comments to D61735: [llvm] X86DiscriminateMemOps: insert debug info when missing.
May 9 2019, 4:20 PM · Restricted Project

May 7 2019

davidxl accepted D61661: [llvm] Avoid div by 0 when updating profile weights..

lgtm

May 7 2019, 6:39 PM · Restricted Project
davidxl added inline comments to D61609: [llvm] Handle missing debug info when updating sample counts.
May 7 2019, 3:12 PM · Restricted Project
davidxl added inline comments to D61609: [llvm] Handle missing debug info when updating sample counts.
May 7 2019, 2:13 PM · Restricted Project

May 6 2019

davidxl added inline comments to D61609: [llvm] Handle missing debug info when updating sample counts.
May 6 2019, 8:35 PM · Restricted Project
davidxl added inline comments to D61609: [llvm] Handle missing debug info when updating sample counts.
May 6 2019, 1:32 PM · Restricted Project

May 1 2019

davidxl accepted D61405: [PGO][CHR] A bug fix..

lgtm

May 1 2019, 3:00 PM · Restricted Project

Apr 30 2019

davidxl accepted D60977: [llvm-profdata] Add overlap command to compute similarity b/w two profile files.

lgtm

Apr 30 2019, 12:02 PM · Restricted Project

Apr 29 2019

davidxl added inline comments to D60977: [llvm-profdata] Add overlap command to compute similarity b/w two profile files.
Apr 29 2019, 2:29 PM · Restricted Project
davidxl added inline comments to D60977: [llvm-profdata] Add overlap command to compute similarity b/w two profile files.
Apr 29 2019, 10:07 AM · Restricted Project

Apr 24 2019

davidxl added inline comments to D60977: [llvm-profdata] Add overlap command to compute similarity b/w two profile files.
Apr 24 2019, 2:19 PM · Restricted Project
davidxl committed rG499c80b89015: Add optional arg to profile count getters to filter synthetic profile count. (authored by davidxl).
Add optional arg to profile count getters to filter synthetic profile count.
Apr 24 2019, 12:50 PM
davidxl committed rL359131: Add optional arg to profile count getters to filter.
Add optional arg to profile count getters to filter
Apr 24 2019, 12:49 PM
davidxl closed D61025: Add an optional arg to include/exclude synthetic profile when query hasProfileData.
Apr 24 2019, 12:49 PM · Restricted Project

Apr 23 2019

davidxl updated the diff for D61025: Add an optional arg to include/exclude synthetic profile when query hasProfileData.

Update related interfaces in ProfileSummaryInfo.

Apr 23 2019, 11:20 PM · Restricted Project
davidxl added a comment to D61025: Add an optional arg to include/exclude synthetic profile when query hasProfileData.

It is tempting to use enum in this case, however I don't see possible extension to the type (in forseable future), so perhaps keep this way.

Apr 23 2019, 5:12 PM · Restricted Project
davidxl updated the diff for D61025: Add an optional arg to include/exclude synthetic profile when query hasProfileData.

Updated the patch to include more APIs.

Apr 23 2019, 3:55 PM · Restricted Project
davidxl added inline comments to D60977: [llvm-profdata] Add overlap command to compute similarity b/w two profile files.
Apr 23 2019, 10:59 AM · Restricted Project
davidxl created D61025: Add an optional arg to include/exclude synthetic profile when query hasProfileData.
Apr 23 2019, 9:12 AM · Restricted Project

Apr 19 2019

davidxl accepted D60911: [PGO/SamplePGO][NFC] Move the function updateProfWeight from Instruction to CallInst.

This is not completely NFC as it modifies branch weight update behavior (though correctly), so please do more pgo testings to avoid surprises (e.g, some weird dependencies on old behavior).

Apr 19 2019, 12:21 PM · Restricted Project
davidxl added a comment to D60903: [SampleFDO] Never set profile entry count to 0.

Looked at the Instruction::updateProfWeight() --- the part that update branch_weights seems bogus -- there is need need to scale branch weight at all.

Apr 19 2019, 10:06 AM · Restricted Project
davidxl added a comment to D60903: [SampleFDO] Never set profile entry count to 0.

Can you clarify? IIRC, we never update the per-call site profile meta data with inline transformations.

Apr 19 2019, 10:02 AM · Restricted Project
davidxl added a comment to D60903: [SampleFDO] Never set profile entry count to 0.

It is possible to for an entry with zero count -- as for instance in instrumentation PGO. Should it be fixed in place where the div by zero happens?

Apr 19 2019, 9:21 AM · Restricted Project

Apr 11 2019

davidxl accepted D60587: Add options for MaxLoadsPerMemcmp(OptSize)..

lgtm

Apr 11 2019, 2:55 PM · Restricted Project

Apr 10 2019

davidxl accepted D60154: [PGO] Better handling of profile hash mismatch.
Apr 10 2019, 12:43 PM · Restricted Project
davidxl added inline comments to D60154: [PGO] Better handling of profile hash mismatch.
Apr 10 2019, 10:32 AM · Restricted Project
davidxl added inline comments to D60154: [PGO] Better handling of profile hash mismatch.
Apr 10 2019, 10:09 AM · Restricted Project

Mar 29 2019

davidxl accepted D59967: [llvm][NFC] Factor out logic for getting incoming & back Loop edges.

lgtm

Mar 29 2019, 9:36 AM · Restricted Project

Mar 28 2019

davidxl added inline comments to D59967: [llvm][NFC] Factor out logic for getting incoming & back Loop edges.
Mar 28 2019, 3:56 PM · Restricted Project

Mar 21 2019

davidxl added a comment to D59514: [PGO] Profile guided code size optimization..

Look fine in general. Easwaran can help with review of pass pipeline changes

Mar 21 2019, 9:13 AM · Restricted Project

Mar 19 2019

davidxl added a comment to D59514: [PGO] Profile guided code size optimization..

Missing unit tests for the feature.

Mar 19 2019, 4:05 PM · Restricted Project
davidxl added a reviewer for D59514: [PGO] Profile guided code size optimization.: eraman.
Mar 19 2019, 12:00 PM · Restricted Project

Mar 12 2019

davidxl added inline comments to D59225: [profile] Support for GCDA profiling in Fuchsia.
Mar 12 2019, 9:29 AM · Restricted Project, Restricted Project
davidxl added inline comments to D54815: [ThinLTO] Add summary entries for index-based WPD.
Mar 12 2019, 9:19 AM · Restricted Project

Mar 11 2019

davidxl added inline comments to D59153: [MBP] Make sure the exit BB is the most possible successor before rotating a loop.
Mar 11 2019, 8:14 PM · Restricted Project

Mar 7 2019

davidxl added inline comments to D58997: Order File Instrumentation: dump the data in compiler-rt (Make it work for Linux/Windows etc).
Mar 7 2019, 8:53 PM · Restricted Project, Restricted Project

Mar 6 2019

davidxl added inline comments to D58997: Order File Instrumentation: dump the data in compiler-rt (Make it work for Linux/Windows etc).
Mar 6 2019, 1:47 PM · Restricted Project, Restricted Project

Mar 5 2019

davidxl added inline comments to D58997: Order File Instrumentation: dump the data in compiler-rt (Make it work for Linux/Windows etc).
Mar 5 2019, 2:37 PM · Restricted Project, Restricted Project

Mar 4 2019

davidxl accepted D54176: [PGO] clang part of change for context-sensitive PGO..

lgtm

Mar 4 2019, 11:06 AM · Restricted Project
davidxl added inline comments to D54176: [PGO] clang part of change for context-sensitive PGO..
Mar 4 2019, 8:34 AM · Restricted Project