Page MenuHomePhabricator

fhahn (Florian Hahn)
User

Projects

User does not belong to any projects.

User Details

User Since
Aug 18 2016, 4:39 AM (178 w, 1 d)

Recent Activity

Yesterday

fhahn planned changes to D72147: [DSE] Add debug counter..

Needs rebase after bottom-up walk changes/

Fri, Jan 17, 9:34 AM · Restricted Project
fhahn planned changes to D72700: [DSE] Add first version of MemorySSA-backed DSE (Bottom up walk)..

Regarding handling the branching example, the solution fhahn proposes sounds reasonable to me.
I was thinking something similar, along the lines of: do the checks bottom-up from both second and third stores during the main algorithm, both find the dead store but do not postdominate it; don't abandon them, but keep this info (include the checks for no intervening reads) for after the main search. The data structure could be a Hashmap<PotentialDeadStore, ListOfDefsOrBlocksWhoFoundThisPotentialDeadStore>. If all paths are covered in the List for a PotentialDeadStore, then it's truly dead.

this seems like it should work.

Fri, Jan 17, 9:34 AM · Restricted Project
fhahn planned changes to D72410: [DSE] Eliminate stores by terminators (free,lifetime.end)..

Needs updating to work bottom-up.

Fri, Jan 17, 9:34 AM · Restricted Project
fhahn added a comment to D72148: [DSE] Support traversing MemoryPhis..

Needs updating to work bottom-up.

Fri, Jan 17, 9:34 AM · Restricted Project
fhahn created D72919: [AArch64] Add custom store lowering for 256 bit non-temporal stores..
Fri, Jan 17, 6:30 AM · Restricted Project
fhahn added a comment to D72832: [NFC][LoopUtils] Added regression test for getEstimatedTripCount..

Could you describe why the changes to run the tests via the pass managers is required? Wouldn't it be sufficient to use initialize the required analysis for the function and use that with getLoopEstimatedTripCount?

Fri, Jan 17, 2:01 AM · Restricted Project
fhahn added reviewers for D72891: Compute ORE, BPI, BFI in Loop passes.: anemet, thegameg.
Fri, Jan 17, 1:56 AM · Restricted Project

Thu, Jan 16

fhahn updated the diff for D72526: [Matrix] Mark expressions shared between multiple remarks..

rebase, use += OpInfoTy operator.

Thu, Jan 16, 12:08 PM · Restricted Project
fhahn updated the diff for D72480: [Matrix] Add info about number of operations to remarks..

Replace OpInfoTy::add with a += operator implementation.

Thu, Jan 16, 12:08 PM · Restricted Project
fhahn added inline comments to D72480: [Matrix] Add info about number of operations to remarks..
Thu, Jan 16, 12:08 PM · Restricted Project
fhahn added a comment to D72280: [Matrix] Add IR MatrixBuilder..

ping

Thu, Jan 16, 4:49 AM · Restricted Project
fhahn added a comment to D72480: [Matrix] Add info about number of operations to remarks..

ping

Thu, Jan 16, 4:46 AM · Restricted Project
fhahn added a comment to D72453: [Matrix] Add optimization remarks for matrix expression..

ping

Thu, Jan 16, 4:46 AM · Restricted Project
fhahn committed rG0b21d552620d: [IR] Mark memset.* intrinsics as IntrWriteMem. (authored by fhahn).
[IR] Mark memset.* intrinsics as IntrWriteMem.
Thu, Jan 16, 2:45 AM
fhahn closed D72789: [IR] Mark memset.* intrinsics as IntrWriteMem..
Thu, Jan 16, 2:45 AM · Restricted Project
fhahn added inline comments to D72732: [GVN] introduce GVNOptions to control GVN pass behavior.
Thu, Jan 16, 2:26 AM · Restricted Project
fhahn committed rG23c113802e21: [LV] Allow assume calls in predicated blocks. (authored by fhahn).
[LV] Allow assume calls in predicated blocks.
Thu, Jan 16, 2:19 AM
fhahn closed D68814: [LV] Allow assume calls in predicated blocks..
Thu, Jan 16, 2:19 AM · Restricted Project
fhahn added a comment to D68814: [LV] Allow assume calls in predicated blocks..

Agree that it's better to merge the new conditional assume tests with the existing unconditional assume tests in the same file.

Thu, Jan 16, 2:17 AM · Restricted Project
fhahn committed rG59ac44b3c129: [LV] Make X86/assume.ll X86 independent (NFC). (authored by fhahn).
[LV] Make X86/assume.ll X86 independent (NFC).
Thu, Jan 16, 2:08 AM

Wed, Jan 15

fhahn accepted D72732: [GVN] introduce GVNOptions to control GVN pass behavior.

LGTM, thanks. Please wait a day or so with committing, in case there are additional comments.

Wed, Jan 15, 2:08 PM · Restricted Project
fhahn added a comment to D69069: [LoopExtractor] Convert LoopExtractor from LoopPass to ModulePass.

Would it be possible to also add some of the test cases for the linked bugs?

This patch fixes a crash. Maybe just add a .ll file that shouldn't crash (with the fix)?!

Wed, Jan 15, 12:23 PM · Restricted Project
fhahn added inline comments to D71578: [CodeMoverUtils] Improve IsControlFlowEquivalent..
Wed, Jan 15, 12:14 PM · Restricted Project
fhahn updated the diff for D72789: [IR] Mark memset.* intrinsics as IntrWriteMem..

Fix test failures, caused by checking fn attribute ids and now memset creates a new attribute combo.

Wed, Jan 15, 11:55 AM · Restricted Project
fhahn added inline comments to D71578: [CodeMoverUtils] Improve IsControlFlowEquivalent..
Wed, Jan 15, 11:18 AM · Restricted Project
fhahn added a comment to D72666: [IR] ArgMemOnly functions with WriteOnly ptr args do not read memory..

I'd prefer to just add writeonly markings in places where they're missing. For llvm.memset in particular, can we mark it IntrWriteMem?

Yes we should probably just mark llvm.memset as IntrWriteMem.

Agreed.

Wed, Jan 15, 10:22 AM · Restricted Project
fhahn created D72789: [IR] Mark memset.* intrinsics as IntrWriteMem..
Wed, Jan 15, 10:22 AM · Restricted Project
fhahn created D72785: [Matrix] Add __builtin_matrix_scalar_multiply to Clang (WIP)..
Wed, Jan 15, 10:03 AM · Restricted Project
fhahn added inline comments to D71578: [CodeMoverUtils] Improve IsControlFlowEquivalent..
Wed, Jan 15, 9:53 AM · Restricted Project
fhahn added a parent revision for D72773: [Matrix] Add __builtin_matrix_{add,sub} to Clang (WIP).: D72281: [Matrix] Add matrix type to Clang (WIP)..
Wed, Jan 15, 9:35 AM · Restricted Project
fhahn added a parent revision for D72772: [Matrix] Add __builtin_matrix_extract to Clang (WIP).: D72281: [Matrix] Add matrix type to Clang (WIP)..
Wed, Jan 15, 9:35 AM · Restricted Project
fhahn added child revisions for D72281: [Matrix] Add matrix type to Clang (WIP).: D72778: [Matrix] Add __builtin_matrix_transpose to Clang (WIP)., D72774: [Matrix] Add __builtin_matrix_multiply to Clang (WIP)., D72773: [Matrix] Add __builtin_matrix_{add,sub} to Clang (WIP)., D72772: [Matrix] Add __builtin_matrix_extract to Clang (WIP)., D72283: [Matrix] Add __builtin_matrix_insert to Clang (WIP)..
Wed, Jan 15, 9:35 AM · Restricted Project
fhahn added a parent revision for D72283: [Matrix] Add __builtin_matrix_insert to Clang (WIP).: D72281: [Matrix] Add matrix type to Clang (WIP)..
Wed, Jan 15, 9:35 AM · Restricted Project
fhahn added a parent revision for D72774: [Matrix] Add __builtin_matrix_multiply to Clang (WIP).: D72281: [Matrix] Add matrix type to Clang (WIP)..
Wed, Jan 15, 9:35 AM · Restricted Project
fhahn added a parent revision for D72778: [Matrix] Add __builtin_matrix_transpose to Clang (WIP).: D72281: [Matrix] Add matrix type to Clang (WIP)..
Wed, Jan 15, 9:35 AM · Restricted Project
fhahn added a child revision for D72281: [Matrix] Add matrix type to Clang (WIP).: D72781: [Matrix] Add __builtin_matrix_column_load to Clang (WIP)..
Wed, Jan 15, 9:35 AM · Restricted Project
fhahn added a parent revision for D72781: [Matrix] Add __builtin_matrix_column_load to Clang (WIP).: D72281: [Matrix] Add matrix type to Clang (WIP)..
Wed, Jan 15, 9:35 AM · Restricted Project
fhahn created D72782: [Matrix] Add __builtin_matrix_column_store to Clang (WIP)..
Wed, Jan 15, 9:35 AM · Restricted Project
fhahn created D72781: [Matrix] Add __builtin_matrix_column_load to Clang (WIP)..
Wed, Jan 15, 9:25 AM · Restricted Project
fhahn added inline comments to D72732: [GVN] introduce GVNOptions to control GVN pass behavior.
Wed, Jan 15, 9:25 AM · Restricted Project
fhahn created D72778: [Matrix] Add __builtin_matrix_transpose to Clang (WIP)..
Wed, Jan 15, 9:15 AM · Restricted Project
fhahn created D72774: [Matrix] Add __builtin_matrix_multiply to Clang (WIP)..
Wed, Jan 15, 9:05 AM · Restricted Project
fhahn created D72773: [Matrix] Add __builtin_matrix_{add,sub} to Clang (WIP)..
Wed, Jan 15, 8:55 AM · Restricted Project
fhahn created D72772: [Matrix] Add __builtin_matrix_extract to Clang (WIP)..
Wed, Jan 15, 8:49 AM · Restricted Project
fhahn created D72770: [test-suite] Add matrix builtin tests (WIP)..
Wed, Jan 15, 8:21 AM · Restricted Project
fhahn added inline comments to D72700: [DSE] Add first version of MemorySSA-backed DSE (Bottom up walk)..
Wed, Jan 15, 6:48 AM · Restricted Project
fhahn added a comment to D72700: [DSE] Add first version of MemorySSA-backed DSE (Bottom up walk)..

I did a few experiment with bottom-up algorithm before the patch i showed on phabricator. my implementation of the bottom-up had similar average complie-time to the current pass on the test-suite but it was only barely removing more stores than the current pass.
i gave up on it because i didn't found a good way forward to make it deal with cases like to the following:

   store i32 0, i32* %Ptr.  ; DEAD
   br i1 %cond, label %a, label %b
a:
  store i32 2, i32* %Ptr
   br label %c
b: 
  store i32 2, i32* %Ptr
  br label %c

which is IMO definitely something we want to do. by the way gcc does this optimization. https://godbolt.org/z/VFBf-c
maybe there is a bottom-up way to deal with this that i didn't thought about. any thought ?

Wed, Jan 15, 5:54 AM · Restricted Project

Tue, Jan 14

fhahn added a comment to D72631: [DSE] Eliminate stores at the end of the function..

Just a general comment here: DSE shouldn't necessarily make all optimizations possible. This one looks like it should be caught by DCE. If it's not, perhaps it would be good to improve DCE. Alternatively, if it's cheap enough, add a comment that it's still worth adding it to DSE.

Tue, Jan 14, 4:04 PM · Restricted Project
fhahn added a comment to D72666: [IR] ArgMemOnly functions with WriteOnly ptr args do not read memory..

I'd prefer to just add writeonly markings in places where they're missing. For llvm.memset in particular, can we mark it IntrWriteMem?

Tue, Jan 14, 3:52 PM · Restricted Project
fhahn added a comment to D60582: [IPSCCP] Use ValueLatticeElement instead of LatticeVal (NFCI).

ping. Eli, do you think the updated approach makes more sense?

Tue, Jan 14, 1:09 PM · Restricted Project
fhahn added a comment to D71836: [IPSCCP] Use ParamState for arguments at call sites..

ping :)

Tue, Jan 14, 11:23 AM · Restricted Project
fhahn added a comment to D68298: [GlobalOpt] Pass DTU to removeUnreachableBlocks instead of recomputing..

I've revert rG192cce10f67e for now.

Tue, Jan 14, 7:05 AM · Restricted Project
fhahn committed rG192cce10f67e: Revert "Recommit "[GlobalOpt] Pass DTU to removeUnreachableBlocks instead of… (authored by fhahn).
Revert "Recommit "[GlobalOpt] Pass DTU to removeUnreachableBlocks instead of…
Tue, Jan 14, 6:56 AM
fhahn added a reverting change for rGa03d7b0f24b6: Recommit "[GlobalOpt] Pass DTU to removeUnreachableBlocks instead of…: rG192cce10f67e: Revert "Recommit "[GlobalOpt] Pass DTU to removeUnreachableBlocks instead of….
Tue, Jan 14, 6:56 AM
fhahn abandoned D72214: [GlobalOpt] Get DT only if it is available..

After thinking about it a bit more, I think this patch makes things too brittle with the legacy pass manager (e.g. we might end up with invalid DTs, if they are not used by GlobalOpt, but removeUnreachableBlocks makes changes. I'll revert D68298 for now.

Tue, Jan 14, 6:55 AM · Restricted Project
fhahn added a comment to D72146: [DSE] Add first version of MemorySSA-backed DSE..

Some comments inline.

Re-adding the inline comment: downwards walks are inefficient. This also currently misses optimization opportunities. In order to not miss anything, all Defs need to be looked at, not only uses, adding more overhead. So it's possible replacing MemDepAnalysis with MemorySSA may not get many benefits.
Maybe do some preliminary performance testing to check trade-offs between this recursive approach, the iterative approach in Tyker's patch, or consider a bottom-up approach?

Tue, Jan 14, 6:35 AM · Restricted Project
fhahn created D72700: [DSE] Add first version of MemorySSA-backed DSE (Bottom up walk)..
Tue, Jan 14, 6:16 AM · Restricted Project

Mon, Jan 13

fhahn added a comment to D72524: [X86] Try to avoid casts around logical vector ops recursively..

clang-tidy: fail. Please fix clang-tidy findings.

Mon, Jan 13, 4:50 PM · Restricted Project
fhahn created D72666: [IR] ArgMemOnly functions with WriteOnly ptr args do not read memory..
Mon, Jan 13, 4:41 PM · Restricted Project
fhahn added a comment to D72146: [DSE] Add first version of MemorySSA-backed DSE..

I think the latest version should be in quite good shape for review. I've linked the follow-on patches which together give a nice improvement in dead stores eliminated. I'll post a patch for partial overwrite tracking tomorrow and I am also working on exploring multiple memory defs.

Mon, Jan 13, 4:13 PM · Restricted Project
fhahn created D72631: [DSE] Eliminate stores at the end of the function..
Mon, Jan 13, 9:19 AM · Restricted Project
fhahn updated the diff for D72410: [DSE] Eliminate stores by terminators (free,lifetime.end)..

rebase

Mon, Jan 13, 9:19 AM · Restricted Project
fhahn created D72628: [DSE] Move state for MemorySSA-drive DSE to DSEState..
Mon, Jan 13, 9:09 AM · Restricted Project
fhahn updated the diff for D72148: [DSE] Support traversing MemoryPhis..

Rebase

Mon, Jan 13, 8:59 AM · Restricted Project
fhahn updated the diff for D72146: [DSE] Add first version of MemorySSA-backed DSE..

Updated to use AA::getModRefInfo and AA::callCapturesBefore similar to DependenceAnalysis. Remove unnecessary getLocForReadEx.

Mon, Jan 13, 8:59 AM · Restricted Project

Sat, Jan 11

fhahn added a comment to D72524: [X86] Try to avoid casts around logical vector ops recursively..

Not sure if its reusable but we already have signExtendBitcastSrcVector which we use for the (i16 bitcast (v16i1 x)) combine

Sat, Jan 11, 4:48 AM · Restricted Project
fhahn updated the diff for D72524: [X86] Try to avoid casts around logical vector ops recursively..

Use SelectionDAG::MaxRecursionDepth, add example to comment.

Sat, Jan 11, 4:37 AM · Restricted Project
fhahn committed rG5d069f4314a0: [X86] Add more complex tests for vector masks used with AND/OR/XOR. (authored by fhahn).
[X86] Add more complex tests for vector masks used with AND/OR/XOR.
Sat, Jan 11, 4:18 AM

Fri, Jan 10

fhahn added a child revision for D72480: [Matrix] Add info about number of operations to remarks.: D72526: [Matrix] Mark expressions shared between multiple remarks..
Fri, Jan 10, 10:51 AM · Restricted Project
fhahn added a parent revision for D72526: [Matrix] Mark expressions shared between multiple remarks.: D72480: [Matrix] Add info about number of operations to remarks..
Fri, Jan 10, 10:51 AM · Restricted Project
fhahn added a comment to D72524: [X86] Try to avoid casts around logical vector ops recursively..

The diff just includes the changes for the newly added tests (which I'll pre-commit before landing this)

Fri, Jan 10, 10:51 AM · Restricted Project
fhahn created D72526: [Matrix] Mark expressions shared between multiple remarks..
Fri, Jan 10, 10:50 AM · Restricted Project
fhahn updated the diff for D72480: [Matrix] Add info about number of operations to remarks..

Handle re-used expressions.

Fri, Jan 10, 10:33 AM · Restricted Project
fhahn updated the diff for D72453: [Matrix] Add optimization remarks for matrix expression..

Handle re-used ops.

Fri, Jan 10, 10:31 AM · Restricted Project
fhahn created D72524: [X86] Try to avoid casts around logical vector ops recursively..
Fri, Jan 10, 10:31 AM · Restricted Project
fhahn added a comment to D72214: [GlobalOpt] Get DT only if it is available..

The old PassManager has the function getAnalysisIfAvailable that should be used in case you only need to update an analysis (equivalent to getCachedResult of the new PassManager). You should probably switch to use this function, instead of the SmallPtrSet<> DTRequested technique.

Fri, Jan 10, 9:23 AM · Restricted Project

Thu, Jan 9

fhahn committed rG730da1ce4731: Merge commit 'refs/am/changes/5a751e747dbf2c267e944aa961e21de7a815e7eb_apple/ma… (authored by fhahn).
Merge commit 'refs/am/changes/5a751e747dbf2c267e944aa961e21de7a815e7eb_apple/ma…
Thu, Jan 9, 5:25 PM
fhahn added a parent revision for D72480: [Matrix] Add info about number of operations to remarks.: D72453: [Matrix] Add optimization remarks for matrix expression..
Thu, Jan 9, 2:09 PM · Restricted Project
fhahn added a child revision for D72453: [Matrix] Add optimization remarks for matrix expression.: D72480: [Matrix] Add info about number of operations to remarks..
Thu, Jan 9, 2:09 PM · Restricted Project
fhahn created D72480: [Matrix] Add info about number of operations to remarks..
Thu, Jan 9, 2:09 PM · Restricted Project
fhahn added a comment to D72214: [GlobalOpt] Get DT only if it is available..

Do you plan to pursue this patch? It would be great to resolve this one way or the other before LLVM 10 branches.

Thu, Jan 9, 1:51 PM · Restricted Project
fhahn updated the summary of D72214: [GlobalOpt] Get DT only if it is available..
Thu, Jan 9, 1:50 PM · Restricted Project
fhahn added a comment to D72416: [Flang] add flang as a new subproject in cmake.

IIUC this is only needed after the flang merge, right? It will break things before the merge. The change is fine, after flang gets merged. IIUC this is not required as preparation for the merge, rather a follow up. Unless I am missing something, it would be good to clarify the title/commit message.

Thu, Jan 9, 11:01 AM · Restricted Project, Restricted Project
fhahn created D72453: [Matrix] Add optimization remarks for matrix expression..
Thu, Jan 9, 7:15 AM · Restricted Project
fhahn added a comment to D72392: [MachineScheduler] Fix the TopDepth/BotHeightReduce latency heuristics.

The diff in llvm/test/CodeGen/X86/testb-je-fusion.ll is:

        movl    %edi, %eax
-       addl    $-512, %eax             # imm = 0xFE00
        movb    $1, (%rsi)
+       addl    $-512, %eax             # imm = 0xFE00
        je      .LBB2_2
...
        movl    %edi, %eax
-       decl    %eax
        movb    $1, (%rsi)
+       decl    %eax
        je      .LBB3_2

The scheduler prefers not to put the addl/decl immediately after the first movl because of the register dependency on eax with latency 1.

Thu, Jan 9, 4:14 AM · Restricted Project
fhahn added a comment to D69103: Backend for NEC SX-Aurora.

I think this breaks http://lab.llvm.org:8011/builders/clang-ppc64le-rhel/builds/425/steps/build%20stage%201/logs/stdio

Thu, Jan 9, 3:07 AM · Restricted Project, Restricted Project
fhahn added a comment to D72392: [MachineScheduler] Fix the TopDepth/BotHeightReduce latency heuristics.

There's a lot of small test changes (expected), but IMO I would be good to have an isolated test only tests the new behavior and shows an improvement (probably best as MIR machine-scheduler only test).

Thu, Jan 9, 2:58 AM · Restricted Project
fhahn committed rGccf24225e3f2: [Matrix] Update shape propagation to iterate until done. (authored by fhahn).
[Matrix] Update shape propagation to iterate until done.
Thu, Jan 9, 2:55 AM
fhahn closed D70901: [Matrix] Update shape propagation to iterate until done..
Thu, Jan 9, 2:54 AM · Restricted Project
fhahn committed rG7adf6644f50a: [Matrix] Propagate and use shape information for loads. (authored by fhahn).
[Matrix] Propagate and use shape information for loads.
Thu, Jan 9, 2:26 AM
fhahn closed D70900: [Matrix] Propagate and use shape information for loads..
Thu, Jan 9, 2:26 AM · Restricted Project
fhahn committed rG459ad8e97e07: [Matrix] Implement back-propagation of shape information. (authored by fhahn).
[Matrix] Implement back-propagation of shape information.
Thu, Jan 9, 1:49 AM
fhahn closed D70899: [Matrix] Implement back-propagation of shape information..
Thu, Jan 9, 1:49 AM · Restricted Project
fhahn removed a parent revision for D70899: [Matrix] Implement back-propagation of shape information.: D70897: [Matrix] Add forward shape propagation and first shape aware lowerings..
Thu, Jan 9, 1:32 AM · Restricted Project
fhahn removed a child revision for D70897: [Matrix] Add forward shape propagation and first shape aware lowerings.: D70899: [Matrix] Implement back-propagation of shape information..
Thu, Jan 9, 1:32 AM · Restricted Project
fhahn removed a child revision for D70900: [Matrix] Propagate and use shape information for loads.: D70899: [Matrix] Implement back-propagation of shape information..
Thu, Jan 9, 1:31 AM · Restricted Project
fhahn removed a parent revision for D70899: [Matrix] Implement back-propagation of shape information.: D70900: [Matrix] Propagate and use shape information for loads..
Thu, Jan 9, 1:31 AM · Restricted Project

Wed, Jan 8

fhahn added inline comments to D72280: [Matrix] Add IR MatrixBuilder..
Wed, Jan 8, 2:04 PM · Restricted Project
fhahn updated the diff for D72280: [Matrix] Add IR MatrixBuilder..

Remove unnecessary ResultNumElementsFlattened, add doc-comments.

Wed, Jan 8, 2:04 PM · Restricted Project
fhahn abandoned D70590: [Examples] Add add_llvm_example_library macro and use it for IR example..
Wed, Jan 8, 1:18 PM · Restricted Project