Page MenuHomePhabricator

hiraditya (Aditya Kumar)
User

Projects

User does not belong to any projects.

User Details

User Since
Mar 5 2014, 4:23 PM (342 w, 1 d)

Recent Activity

Wed, Sep 9

hiraditya added a comment to D59715: [HotColdSplit] Reflect full cost of parameters in split penalty.

Any plans to merge this patch?

Wed, Sep 9, 10:00 AM · Restricted Project
hiraditya accepted D87347: [NFC] Fix compiler warnings due to integer comparison of different signedness.
Wed, Sep 9, 9:51 AM · Restricted Project, Restricted Project

Fri, Aug 28

hiraditya added a comment to D85368: [llvm][CodeGen] Machine Function Splitter.

nit: If FIXME's are mostly future works, then please replace them with TODOs.

Fri, Aug 28, 8:58 AM · Restricted Project
hiraditya added inline comments to D85368: [llvm][CodeGen] Machine Function Splitter.
Fri, Aug 28, 8:43 AM · Restricted Project

Aug 21 2020

hiraditya added a comment to D79485: [BPI] Improve static heuristics for "cold" paths..

Is the test failure related to this patch?

Aug 21 2020, 3:18 PM · Restricted Project

Aug 17 2020

hiraditya added a reviewer for D86032: NFC: [GVNHoist] Outline functions from the class: hiraditya.
Aug 17 2020, 5:41 PM · Restricted Project
hiraditya added a comment to D86032: NFC: [GVNHoist] Outline functions from the class.

Self approving because this is NFC change to outline function definitions.

Aug 17 2020, 5:40 PM · Restricted Project
hiraditya committed rG370330f084c0: NFC: [GVNHoist] Outline functions from the class (authored by hiraditya).
NFC: [GVNHoist] Outline functions from the class
Aug 17 2020, 5:40 PM
hiraditya closed D86032: NFC: [GVNHoist] Outline functions from the class.
Aug 17 2020, 5:40 PM · Restricted Project
hiraditya updated the diff for D86032: NFC: [GVNHoist] Outline functions from the class.

rebase

Aug 17 2020, 1:51 PM · Restricted Project
hiraditya added a comment to D85628: [HotColdSplitting] Add command line options for supplying cold function names via user input..

then it may be possible to construct a synthetic/fake profile as a pre-processing step

Aug 17 2020, 11:31 AM · Restricted Project
hiraditya updated the diff for D86032: NFC: [GVNHoist] Outline functions from the class.

Rebase

Aug 17 2020, 11:02 AM · Restricted Project
hiraditya committed rGcb6e6936db35: NFC: [GVNHoist] Hoist loop invariant code and rename variables for readability (authored by hiraditya).
NFC: [GVNHoist] Hoist loop invariant code and rename variables for readability
Aug 17 2020, 9:44 AM
hiraditya closed D86031: NFC: [GVNHoist] Hoist loop invariant code and rename variables for readability.
Aug 17 2020, 9:43 AM · Restricted Project
hiraditya updated the diff for D86031: NFC: [GVNHoist] Hoist loop invariant code and rename variables for readability.

Addressed fhahn's comments

Aug 17 2020, 9:22 AM · Restricted Project
hiraditya added a comment to D82892: [NFC] Methods to compare IR added in each IR subclass.

please run clang-format

Aug 17 2020, 9:17 AM · Restricted Project
hiraditya added a reviewer for D86031: NFC: [GVNHoist] Hoist loop invariant code and rename variables for readability: sebpop.
Aug 17 2020, 6:35 AM · Restricted Project

Aug 15 2020

hiraditya closed D85975: [NFC] Fix typo and variable names.

49a944af7f1980b54d8a2be0ef640f5a956bc423

Aug 15 2020, 10:12 PM · Restricted Project
hiraditya requested review of D86032: NFC: [GVNHoist] Outline functions from the class.
Aug 15 2020, 8:44 PM · Restricted Project
hiraditya requested review of D86031: NFC: [GVNHoist] Hoist loop invariant code and rename variables for readability.
Aug 15 2020, 8:00 PM · Restricted Project
hiraditya committed rG49a944af7f19: [NFC] Fix typo and variable names (authored by hiraditya).
[NFC] Fix typo and variable names
Aug 15 2020, 9:06 AM

Aug 14 2020

hiraditya added a comment to D85975: [NFC] Fix typo and variable names.

FWIW C++ doesn't really have a lattice anymore: https://wg21.link/p0418

Is there a guidance for the users of 'isStrongerThan', isStrongerThanUnordered etc.?

Aug 14 2020, 11:12 AM · Restricted Project
Herald added a project to D53779: [CodeExtractor] Allow extracting allocas within simple stack{save,restore} pairs: Restricted Project.

Is this patch still useful now that D53514 has landed?

Aug 14 2020, 10:47 AM · Restricted Project
hiraditya added inline comments to D82892: [NFC] Methods to compare IR added in each IR subclass.
Aug 14 2020, 10:27 AM · Restricted Project
hiraditya added reviewers for D85975: [NFC] Fix typo and variable names: jfb, chandlerc.
Aug 14 2020, 10:24 AM · Restricted Project
hiraditya added inline comments to D59715: [HotColdSplit] Reflect full cost of parameters in split penalty.
Aug 14 2020, 10:17 AM · Restricted Project
hiraditya added a comment to D79485: [BPI] Improve static heuristics for "cold" paths..

please run clang-format.

Aug 14 2020, 9:24 AM · Restricted Project
hiraditya added a comment to D79485: [BPI] Improve static heuristics for "cold" paths..

..anyway I can try to describe how thing work using some example. Is this what you are looking for?

yes. Thank you.

Aug 14 2020, 9:23 AM · Restricted Project
hiraditya requested review of D85975: [NFC] Fix typo and variable names.
Aug 14 2020, 9:08 AM · Restricted Project
hiraditya added a comment to D85368: [llvm][CodeGen] Machine Function Splitter.

Can we add more test cases to include eh_pad, invokeinst,

Aug 14 2020, 12:23 AM · Restricted Project
hiraditya requested changes to D85368: [llvm][CodeGen] Machine Function Splitter.

please run clang-format on the patch.

Aug 14 2020, 12:10 AM · Restricted Project
hiraditya added a reviewer for D85368: [llvm][CodeGen] Machine Function Splitter: hiraditya.
Aug 14 2020, 12:07 AM · Restricted Project
hiraditya added a comment to D85368: [llvm][CodeGen] Machine Function Splitter.

Overall approach looks good to me even when we don't see good SPEC-17 numbers as the optimization is intended to reduce page faults. The improvements would be more pronounced in large applications. I'll review the code in more detail in the next few days. Thanks for working on this.

Aug 14 2020, 12:07 AM · Restricted Project

Aug 13 2020

hiraditya added a comment to D79485: [BPI] Improve static heuristics for "cold" paths..

Is this work based on any paper/implementation?
Can we add some documentation at the top of the file to get an overall idea of the cost model?

Aug 13 2020, 3:41 PM · Restricted Project
hiraditya added a comment to D85881: Fix PR45442: Bail out when MemorySSA information is not available.

Fixed the bug in: https://bugs.llvm.org/show_bug.cgi?id=45442

Aug 13 2020, 11:28 AM · Restricted Project
hiraditya committed rG1a8c9cd1d96e: Fix PR45442: Bail out when MemorySSA information is not available (authored by hiraditya).
Fix PR45442: Bail out when MemorySSA information is not available
Aug 13 2020, 11:27 AM
hiraditya closed D85881: Fix PR45442: Bail out when MemorySSA information is not available.
Aug 13 2020, 11:27 AM · Restricted Project
hiraditya updated the diff for D85881: Fix PR45442: Bail out when MemorySSA information is not available.
Aug 13 2020, 11:25 AM · Restricted Project
hiraditya added a comment to D85881: Fix PR45442: Bail out when MemorySSA information is not available.

Updated test cases.

Aug 13 2020, 10:30 AM · Restricted Project
hiraditya updated the diff for D85881: Fix PR45442: Bail out when MemorySSA information is not available.
Aug 13 2020, 10:30 AM · Restricted Project
hiraditya added a comment to D85873: Add cold attribute to one time construction APIs.

FYI: libstdc++ patch sent for review: https://gcc.gnu.org/pipermail/gcc-patches/2020-August/551934.html

Aug 13 2020, 9:59 AM · Restricted Project
hiraditya added inline comments to D85881: Fix PR45442: Bail out when MemorySSA information is not available.
Aug 13 2020, 9:54 AM · Restricted Project
hiraditya committed rG44716856db59: Fix PR45442: Bail out when MemorySSA information is not available (authored by hiraditya).
Fix PR45442: Bail out when MemorySSA information is not available
Aug 13 2020, 9:32 AM
hiraditya accepted D85881: Fix PR45442: Bail out when MemorySSA information is not available.

Self approving as it is a trivial change and fixes PR45442

Aug 13 2020, 9:31 AM · Restricted Project
hiraditya committed rGd54f5979bb82: Add cold attribute to one time construction APIs (authored by hiraditya).
Add cold attribute to one time construction APIs
Aug 13 2020, 9:30 AM
hiraditya closed D85873: Add cold attribute to one time construction APIs.
Aug 13 2020, 9:30 AM · Restricted Project
hiraditya added a comment to D85628: [HotColdSplitting] Add command line options for supplying cold function names via user input..
In D85628#2214119, @jfb wrote:
In D85628#2213940, @rjf wrote:
In D85628#2213919, @vsk wrote:

I’m not convinced this is a good idea. In what use case is it not possible to mark up relevant functions? It doesn’t make sense to me to make alternations to standard library functions within the compiler. It seems better to simply patch the standard library. In some cases llvm does infer function attributes for library functions, but these are generally lower level attributes that can’t be specified at the source level, and the attribute is made available to other passes in the pipeline.

Do you mean this patch isn't a good idea in general, or the recent revision isn't a good idea? For the latter, I'm not sure if you meant we should not outline declarations or we should not split the original loop into two (e.g. marking as cold before outlining). IMO splitting the loop into two simply addresses what the original intent of what we're doing, which is to mark certain functions as cold before outlining. Whereas, if we don't outline declarations via user-provided input, it renders @hiraditya 's proposed testcase useless. Alternatively, we don't have to make the testcase involving standard library functions if that's what you want :).

My understanding is that today code can be considered "cold" based on the following:

  1. Attribute on the function
  2. Likely / unlikely annotations
  3. Profile information
  4. Other compiler heuristics

This adds another way to do it, but it's kind of a side-injection and it doesn't seem particularly principled. Presumably the list you're feeding through the command-line comes from a profile? Why isn't it provided as profile information?

Aug 13 2020, 8:00 AM · Restricted Project
hiraditya added a comment to D85628: [HotColdSplitting] Add command line options for supplying cold function names via user input..

The patch looks legit. Wonder if such a patch should be sent to libstdc++ too.

Aug 13 2020, 7:42 AM · Restricted Project
hiraditya updated the diff for D85881: Fix PR45442: Bail out when MemorySSA information is not available.
Aug 13 2020, 12:11 AM · Restricted Project
hiraditya requested review of D85881: Fix PR45442: Bail out when MemorySSA information is not available.
Aug 13 2020, 12:08 AM · Restricted Project

Aug 12 2020

hiraditya added a comment to D32140: Global code motion of congruent computations.

https://bugs.llvm.org/show_bug.cgi?id=42283 has been fixed.

Aug 12 2020, 11:21 PM · Restricted Project
hiraditya closed D85860: [HotColdSplit] Fix variable name spelling.
Aug 12 2020, 10:59 PM · Restricted Project
hiraditya added a comment to D85860: [HotColdSplit] Fix variable name spelling.

Closed in:
f902a7eccf30a762d9a533c3884edfb692c26a09

Aug 12 2020, 10:59 PM · Restricted Project
hiraditya committed rGf902a7eccf30: [HotColdSplit] Fix variable name spelling (authored by hiraditya).
[HotColdSplit] Fix variable name spelling
Aug 12 2020, 10:59 PM
hiraditya updated the summary of D85873: Add cold attribute to one time construction APIs.
Aug 12 2020, 10:30 PM · Restricted Project
hiraditya added a comment to D85628: [HotColdSplitting] Add command line options for supplying cold function names via user input..

For my 2nd question, this patch is what I think how this should be done: https://reviews.llvm.org/D79485

Aug 12 2020, 10:29 PM · Restricted Project
hiraditya added a reviewer for D79485: [BPI] Improve static heuristics for "cold" paths.: hiraditya.
Aug 12 2020, 10:26 PM · Restricted Project
hiraditya added a comment to D85628: [HotColdSplitting] Add command line options for supplying cold function names via user input..
In D85628#2214536, @rjf wrote:

I think you missed Aditya's point here: he's saying that certain things like outlining __cxa* functions might be unwise to mark as cold in general

Maybe I missed that, or maybe I am missing some context. I didn't think there was a top-line goal of injecting cold attributes to arbitrary functions.

My understanding is that a key motivating case is minimizing native codegen for local static variables by understanding that the slow path is definitionally cold. If coldness propagates, then as long as __cxa_guard_acquire is attributed as cold, coldness propagation should extend to everywhere of interest. And since __cxa_guard_acquire is used for only one purpose, namely guarding local static variable initialization, and since that purpose is definitionally cold, it should be attributed as cold. I didn't think there was a need to inject cold attributes to other functions.

When it comes to library functions which are cold, presumably we can just patch libraries with cold-attributed function definitions but unattributed declarations, and attribute the declarations.

Added a patch to libcxxabi: https://reviews.llvm.org/D85873

Aug 12 2020, 10:24 PM · Restricted Project
hiraditya requested review of D85873: Add cold attribute to one time construction APIs.
Aug 12 2020, 10:14 PM · Restricted Project
hiraditya accepted D85860: [HotColdSplit] Fix variable name spelling.
Aug 12 2020, 9:38 PM · Restricted Project
hiraditya updated subscribers of D85628: [HotColdSplitting] Add command line options for supplying cold function names via user input..

Apparently there is already support for extended binary profile format (https://reviews.llvm.org/D66766) and we maybe able to use that. Thanks to @wenlei for sharing this information.

Aug 12 2020, 6:13 PM · Restricted Project
hiraditya added a comment to D85628: [HotColdSplitting] Add command line options for supplying cold function names via user input..

I don't think we need to mark the object constructor as cold. We want to mark inlined slow paths of local static variables (the call to __cxa_guard_acquire, the call to the object constructor, etc.,) as cold.

Aug 12 2020, 4:24 PM · Restricted Project
hiraditya added a comment to D85628: [HotColdSplitting] Add command line options for supplying cold function names via user input..

It doesn’t make sense to me to make alternations to standard library functions within the compiler. It seems better to simply patch the standard library.

Aug 12 2020, 3:29 PM · Restricted Project
hiraditya added inline comments to D85628: [HotColdSplitting] Add command line options for supplying cold function names via user input..
Aug 12 2020, 12:28 PM · Restricted Project
hiraditya added inline comments to D85628: [HotColdSplitting] Add command line options for supplying cold function names via user input..
Aug 12 2020, 12:26 PM · Restricted Project
hiraditya added inline comments to D85628: [HotColdSplitting] Add command line options for supplying cold function names via user input..
Aug 12 2020, 12:14 PM · Restricted Project
hiraditya added inline comments to D85616: Improved MergeFunctions to merge similar functions.
Aug 12 2020, 6:13 AM · Restricted Project
hiraditya added a comment to D85628: [HotColdSplitting] Add command line options for supplying cold function names via user input..
In D85628#2212047, @vsk wrote:

Any reason not to mark up the relevant functions with __attribute__((cold)) directly?

Aug 12 2020, 5:57 AM · Restricted Project

Aug 10 2020

hiraditya added a comment to D85616: Improved MergeFunctions to merge similar functions.

Please fix clang-tidy warnings.

Aug 10 2020, 7:20 AM · Restricted Project
hiraditya added inline comments to D82892: [NFC] Methods to compare IR added in each IR subclass.
Aug 10 2020, 7:19 AM · Restricted Project
hiraditya added inline comments to D85628: [HotColdSplitting] Add command line options for supplying cold function names via user input..
Aug 10 2020, 7:17 AM · Restricted Project
hiraditya added inline comments to D85628: [HotColdSplitting] Add command line options for supplying cold function names via user input..
Aug 10 2020, 7:17 AM · Restricted Project

Aug 9 2020

hiraditya updated subscribers of D85368: [llvm][CodeGen] Machine Function Splitter.

Thanks for adding the results, could you share the script to measure bootstrap numbers?

Aug 9 2020, 5:03 PM · Restricted Project
hiraditya committed rG53ac14484869: [HotColdSplit] Add options for splitting cold functions in separate section (authored by hiraditya).
[HotColdSplit] Add options for splitting cold functions in separate section
Aug 9 2020, 8:49 AM
hiraditya closed D85331: [HotColdSplit] Add options for splitting cold functions in separate section.
Aug 9 2020, 8:49 AM · Restricted Project
hiraditya accepted D85331: [HotColdSplit] Add options for splitting cold functions in separate section.
Aug 9 2020, 7:16 AM · Restricted Project

Aug 7 2020

hiraditya added a comment to D68076: [AArch64] Enable unwind tables by default for Gnu targets.

cc: @t.p.northover does this fix look reasonable for PR37240?

Aug 7 2020, 5:30 PM · Restricted Project
hiraditya added a comment to D85368: [llvm][CodeGen] Machine Function Splitter.

We evaluated the Machine Function Splitter pass on clang bootstrap and SPECInt 2017.

Aug 7 2020, 5:27 PM · Restricted Project
hiraditya added inline comments to D85368: [llvm][CodeGen] Machine Function Splitter.
Aug 7 2020, 5:23 PM · Restricted Project
hiraditya accepted D85569: [NVPTX] Fix typo in lit test.

LGTM. nice find!

Aug 7 2020, 5:11 PM · Restricted Project
hiraditya added a reviewer for D85569: [NVPTX] Fix typo in lit test: hiraditya.
Aug 7 2020, 5:10 PM · Restricted Project

Aug 6 2020

hiraditya added inline comments to D59715: [HotColdSplit] Reflect full cost of parameters in split penalty.
Aug 6 2020, 7:39 PM · Restricted Project

Aug 5 2020

hiraditya added a comment to D85368: [llvm][CodeGen] Machine Function Splitter.

Please share performance numbers for publicly available workload(s).

Aug 5 2020, 6:27 PM · Restricted Project

Aug 4 2020

hiraditya added a comment to D85148: Fix ARM build bots failures due to disabled x86_64-apple target.

Fixed in: D85232

Aug 4 2020, 1:53 PM · Restricted Project
hiraditya added a comment to D85215: [HotColdSplit] Remove target triples from architecture-agnostic testcases.

Fixed in: D85232

Aug 4 2020, 1:52 PM · Restricted Project
hiraditya added a comment to D85232: [HotColdSplit] Add test case for unlikely attribute in outlined function.

The ARM build bots do not compile this target as part of their build, causing this test to abort when '-codegenprepare' is added without any REQUIRES clause.

Aug 4 2020, 11:29 AM · Restricted Project
hiraditya requested review of D85232: [HotColdSplit] Add test case for unlikely attribute in outlined function.
Aug 4 2020, 11:28 AM · Restricted Project
hiraditya added a comment to D85215: [HotColdSplit] Remove target triples from architecture-agnostic testcases.

reverted : D85229

Aug 4 2020, 11:18 AM · Restricted Project
hiraditya added a comment to D85148: Fix ARM build bots failures due to disabled x86_64-apple target.

Reverted my original diff; D85229

Aug 4 2020, 11:18 AM · Restricted Project
hiraditya added a reverting change for rGaa1f905890fb: [HotColdSplit] Add test case for unlikely attribute in outlined function: D85229: Revert "[HotColdSplit] Add test case for unlikely attribute in outlined function".
Aug 4 2020, 11:03 AM
hiraditya requested review of D85229: Revert "[HotColdSplit] Add test case for unlikely attribute in outlined function".
Aug 4 2020, 11:03 AM · Restricted Project
hiraditya added a reverting change for D69384: [HotColdSplit] Add unlikely attribute to outlined function: D85229: Revert "[HotColdSplit] Add test case for unlikely attribute in outlined function".
Aug 4 2020, 11:03 AM · Restricted Project
hiraditya abandoned D85215: [HotColdSplit] Remove target triples from architecture-agnostic testcases.

will revert the old patch.

Aug 4 2020, 10:53 AM · Restricted Project
hiraditya commandeered D85215: [HotColdSplit] Remove target triples from architecture-agnostic testcases.
Aug 4 2020, 10:53 AM · Restricted Project
hiraditya added a comment to D85148: Fix ARM build bots failures due to disabled x86_64-apple target.

This looks like a more reasonable fix for now.

Aug 4 2020, 10:51 AM · Restricted Project
hiraditya added a comment to D85215: [HotColdSplit] Remove target triples from architecture-agnostic testcases.

Should I land D85148 then? I'd like to keep the test case if possible.

Aug 4 2020, 10:50 AM · Restricted Project
hiraditya added reviewers for D85215: [HotColdSplit] Remove target triples from architecture-agnostic testcases: vsk, tejohnson.
Aug 4 2020, 8:55 AM · Restricted Project
hiraditya added a comment to D69384: [HotColdSplit] Add unlikely attribute to outlined function.

Fix available in: D85215

Aug 4 2020, 8:54 AM · Restricted Project
hiraditya accepted D85215: [HotColdSplit] Remove target triples from architecture-agnostic testcases.

Thanks for fixing it quickly @rjf

Aug 4 2020, 8:54 AM · Restricted Project
hiraditya added a comment to D69384: [HotColdSplit] Add unlikely attribute to outlined function.

Looking into this. Seems like removing target triple should fix it.

Aug 4 2020, 8:48 AM · Restricted Project