sgraf (Sebastian Graf)
User

Projects

User does not belong to any projects.

User Details

User Since
Apr 12 2017, 7:08 AM (79 w, 5 d)

Recent Activity

Today

sgraf added a comment to D5232: Remove StgBinderInfo and related computation in CoreToStg.

I offered my opinion in https://ghc.haskell.org/trac/ghc/ticket/15770#comment:5:

Mon, Oct 22, 11:01 AM

Fri, Oct 19

sgraf added a comment to D5224: Implement late lambda lift.

Here's a paste with the NoFib results: P189

Fri, Oct 19, 12:07 PM
sgraf updated the diff for D5224: Implement late lambda lift.
  • Comments only
Fri, Oct 19, 12:04 PM

Sat, Oct 13

sgraf updated the diff for D5224: Implement late lambda lift.
  • Move StgSubst to stgSyn
  • Comments only
  • Remove dead binder
Sat, Oct 13, 10:48 AM

Fri, Oct 12

sgraf added a comment to D5224: Implement late lambda lift.

I identified a few points worth discussing below.

Fri, Oct 12, 5:27 AM
sgraf created D5224: Implement late lambda lift.
Fri, Oct 12, 5:19 AM

Tue, Oct 9

sgraf updated the summary of D5153: Add RubbishLit for absent bindings of UnliftedRep.
Tue, Oct 9, 3:51 PM
sgraf added a comment to D5153: Add RubbishLit for absent bindings of UnliftedRep.

Would you like to do a nofib before-and-after comparison? I don't expect the numbers to budge significantly, but I've been wrong before!

Tue, Oct 9, 10:04 AM
sgraf added a comment to D5153: Add RubbishLit for absent bindings of UnliftedRep.

I added a test that checks for the type signature of the workers ($wmutVar and $warray), which should be forall a. Int# -> Int# in both cases.

Tue, Oct 9, 5:57 AM
sgraf added inline comments to D5153: Add RubbishLit for absent bindings of UnliftedRep.
Tue, Oct 9, 5:57 AM
sgraf updated the diff for D5153: Add RubbishLit for absent bindings of UnliftedRep.
  • Add regression test
  • Reformulate comment for Nothing case in mk_absent_let
Tue, Oct 9, 5:33 AM

Mon, Oct 8

sgraf added a comment to D5153: Add RubbishLit for absent bindings of UnliftedRep.

Sorry for the delay. At first, I played around with an assertion, but that triggered due to mysterious reasons that I'll tackle in a later patch...

Mon, Oct 8, 8:56 AM
sgraf updated the diff for D5153: Add RubbishLit for absent bindings of UnliftedRep.
  • Clarifying comment about when mk_absent_let returns Nothing
Mon, Oct 8, 8:54 AM

Fri, Oct 5

sgraf updated the diff for D5153: Add RubbishLit for absent bindings of UnliftedRep.
  • Add note about RubbishLit
Fri, Oct 5, 4:51 AM
sgraf added a comment to D5153: Add RubbishLit for absent bindings of UnliftedRep.

See https://phabricator.haskell.org/D5153#142041 for the rationale behind which things are lowered as () where in the pipeline.
No worries, I was (and am) pretty busy myself.

Fri, Oct 5, 4:51 AM

Sun, Sep 23

sgraf added a comment to D5040: Surprising error message with bang pattern.

No problem. Thanks for your patience!

Sun, Sep 23, 7:32 AM

Sep 22 2018

sgraf added a comment to D5040: Surprising error message with bang pattern.

Nice! See below. Just make the warning enabled by default and this thing is good to go.

Sep 22 2018, 5:46 PM
sgraf added inline comments to D5040: Surprising error message with bang pattern.
Sep 22 2018, 4:34 AM

Sep 21 2018

sgraf added a comment to D5040: Surprising error message with bang pattern.

Looks nearly finished to me. Only a few final issues to resolve.

Sep 21 2018, 3:45 AM

Sep 20 2018

sgraf added inline comments to D5040: Surprising error message with bang pattern.
Sep 20 2018, 8:53 AM
sgraf added inline comments to D5040: Surprising error message with bang pattern.
Sep 20 2018, 6:11 AM
sgraf added a comment to D5040: Surprising error message with bang pattern.

A few more notes. We're getting there!

Sep 20 2018, 2:47 AM

Sep 19 2018

sgraf updated the diff for D5153: Add RubbishLit for absent bindings of UnliftedRep.
  • Lower RubbishLit to () instead of NULL
Sep 19 2018, 7:39 AM
sgraf added a comment to D5153: Add RubbishLit for absent bindings of UnliftedRep.

Sorry for the sweep of comments.

Sep 19 2018, 7:18 AM
sgraf added inline comments to D5153: Add RubbishLit for absent bindings of UnliftedRep.
Sep 19 2018, 6:46 AM
sgraf added inline comments to D5153: Add RubbishLit for absent bindings of UnliftedRep.
Sep 19 2018, 6:46 AM
sgraf added inline comments to D5153: Add RubbishLit for absent bindings of UnliftedRep.
Sep 19 2018, 6:28 AM
sgraf added inline comments to D5153: Add RubbishLit for absent bindings of UnliftedRep.
Sep 19 2018, 5:42 AM
sgraf added inline comments to D5153: Add RubbishLit for absent bindings of UnliftedRep.
Sep 19 2018, 3:58 AM
sgraf updated the diff for D5153: Add RubbishLit for absent bindings of UnliftedRep.
  • Handle literals like variables in expr_ok
  • Explicitly state the pre-condition of myCollectArgs
  • Clarify when mk_absent_let returns Nothing
Sep 19 2018, 3:57 AM
sgraf added a comment to D5040: Surprising error message with bang pattern.

@sgraf I just realized we never check if we actually deal with ! just if infix expression is followed immediately by var.

Sep 19 2018, 2:23 AM

Sep 18 2018

sgraf added a comment to D5040: Surprising error message with bang pattern.

Some remaining points:

Sep 18 2018, 10:42 AM
sgraf added inline comments to D5040: Surprising error message with bang pattern.
Sep 18 2018, 10:15 AM
sgraf added a comment to D5153: Add RubbishLit for absent bindings of UnliftedRep.

Addressed the remaining issue about absent_expr_of.

Sep 18 2018, 10:00 AM
sgraf updated the diff for D5153: Add RubbishLit for absent bindings of UnliftedRep.
  • Comment about why myCollectArgs gets confused
  • Refactored to a minimal diff
Sep 18 2018, 9:54 AM
sgraf added inline comments to D5040: Surprising error message with bang pattern.
Sep 18 2018, 9:46 AM
sgraf added inline comments to D5153: Add RubbishLit for absent bindings of UnliftedRep.
Sep 18 2018, 8:02 AM
sgraf updated the diff for D5153: Add RubbishLit for absent bindings of UnliftedRep.
  • Merge branch 'abs-lit' of github.com:sgraf812/ghc into abs-lit
  • Fixed obsolete comment
  • Add alphaTyVarUnliftedRep
  • Comment about why Lit RubbishLit gets a special treatment in CoreUtils.hs
  • Why we lower RubbishLit as NULL
  • Resolve the FIXME
Sep 18 2018, 8:01 AM
sgraf added a comment to D5040: Surprising error message with bang pattern.

There isn't really a place with more whitespace knowledge in the parser than where you added the check. Whitespace is discarded by the Lexer (well, mostly, except indentation stuff), the only way to recover it is by comparing where tokens begin and end. So this is basically the way to go, but I think the same check could also take place in the renamer. Whatever, both is fine, I guess.

Sep 18 2018, 7:30 AM
sgraf added a comment to D5131: Make sure forM_ and related functions fuse cleanly.

While I *can* reproduce most of them locally, they also reproduce on my base commit (which was ghc-8.6.1-beta1 locally), even with GHC 8.4.3 some of them fail.
I'm not sure why they weren't reported by an earlier validate and I don't think my patch is responsible for any of the alleged regressions.

Sep 18 2018, 5:32 AM
sgraf added a comment to D5131: Make sure forM_ and related functions fuse cleanly.

Right, I wasn't aware there were stat failures in the test suite. Let's see if I can reproduce them locally.

Sep 18 2018, 4:29 AM

Sep 17 2018

sgraf added a comment to D5131: Make sure forM_ and related functions fuse cleanly.

Sorry, but is this blocked by me failing to see the "commit now" button?

Sep 17 2018, 3:23 PM
sgraf added a comment to D5153: Add RubbishLit for absent bindings of UnliftedRep.

I wasn't sure about how to synthesise the type variable in forall (a :: TYPE 'UnliftedRep). a.

Sep 17 2018, 7:11 AM
sgraf updated the summary of D5153: Add RubbishLit for absent bindings of UnliftedRep.
Sep 17 2018, 7:07 AM
sgraf updated the summary of D5153: Add RubbishLit for absent bindings of UnliftedRep.
Sep 17 2018, 7:07 AM
Herald added a reviewer for D5153: Add RubbishLit for absent bindings of UnliftedRep: goldfire.
Sep 17 2018, 7:05 AM
sgraf abandoned D4547: Fix inlining of 'c' in efdt{Int,Word}{Up,Dn}FB.

The followup is D5131.

Sep 17 2018, 2:27 AM

Sep 16 2018

sgraf added a comment to D5040: Surprising error message with bang pattern.

Hey, sorry for the delayed reply. I'm not really familiar with the parser, but it looks like infixexp_top at https://github.com/ghc/ghc/blob/master/compiler/parser/Parser.y#L2470 might be the place to insert the check. Note that that's the production the result of which is identified with $1 in the piece of code you linked to.

Sep 16 2018, 3:24 AM

Sep 7 2018

sgraf added a comment to D5040: Surprising error message with bang pattern.

Hmm... I haven't touched anything parser related yet, but couldn't you just look into the SrcSpan to see where the ! began (srcLocCol looks promising, make sure they are on the same line, though) and check that the variable starts immediately after? That wouldn't leave room for whitespace. And given that there already is hintBangPat, I think it makes sense to put the check there.

Sep 7 2018, 4:57 PM
sgraf added a comment to D5040: Surprising error message with bang pattern.

To not complicate matters too much, GHC's parser accepts much more programs than it really should and instead rejects them in a later semantic pass. This practice isn't even unique to GHC, I think.
This also applies to fiddly stuff like BangPatterns. Take a look here: https://github.com/ghc/ghc/blob/43b08cfbac5ce7ad6fc245651329094896de06e0/compiler/parser/RdrHsSyn.hs#L1263

Sep 7 2018, 9:48 AM
sgraf added a comment to D5040: Surprising error message with bang pattern.

I don't think this should fail with an error, you could write a valid haskell program with this, after all:

Sep 7 2018, 9:18 AM

Sep 6 2018

sgraf updated the diff for D5131: Make sure forM_ and related functions fuse cleanly.

Updated Note

Sep 6 2018, 1:50 PM

Sep 5 2018

sgraf updated the diff for D5131: Make sure forM_ and related functions fuse cleanly.

Push to staging

Sep 5 2018, 2:29 PM
sgraf created D5131: Make sure forM_ and related functions fuse cleanly.
Sep 5 2018, 7:57 AM

Aug 22 2018

sgraf updated the diff for D5058: Make lambda fit for MFP.

Add simpleEvalCon

Aug 22 2018, 11:25 AM
sgraf added a comment to D5058: Make lambda fit for MFP.

Sorry, I was on vacation. I'll finish this in a moment.

Aug 22 2018, 10:47 AM

Aug 12 2018

sgraf updated the diff for D5058: Make lambda fit for MFP.

Fix it without overlapping instances

Aug 12 2018, 1:23 PM

Aug 10 2018

sgraf added inline comments to D5058: Make lambda fit for MFP.
Aug 10 2018, 11:42 AM
sgraf added reviewers for D5058: Make lambda fit for MFP: RyanGlScott, bgamari.
Aug 10 2018, 11:17 AM
sgraf created D5058: Make lambda fit for MFP.
Aug 10 2018, 11:17 AM

Aug 3 2018

sgraf added a comment to D4969: Fix a major copy'n'paste error in LLVM CodeGen.

Is there any news on why the testcase fails in CI? It also appears there is some secondary perf failure:

Aug 3 2018, 3:59 AM

Jul 17 2018

sgraf updated the diff for D4969: Fix a major copy'n'paste error in LLVM CodeGen.

Thanks! This should work now and make test TEST=T10962 actually reproduces the bug.

Jul 17 2018, 6:07 AM
sgraf added a comment to D4969: Fix a major copy'n'paste error in LLVM CodeGen.

Indeed, when I run that test case with -fllvm, it produces the following output:

Jul 17 2018, 5:51 AM
sgraf added a comment to D4969: Fix a major copy'n'paste error in LLVM CodeGen.

Actually, there is a test merged with D4605 that I think should have caught this, but appearently doesn't. Either because it's not run with LLVM or because the noinline builtin doesn't work the way I thought.

Jul 17 2018, 5:36 AM

Jul 16 2018

sgraf added inline comments to D4592: Add 'addWordC#' PrimOp.
Jul 16 2018, 3:25 AM
sgraf added a comment to D4969: Fix a major copy'n'paste error in LLVM CodeGen.

I uploaded this diff manually through the web interface, as I have still problems connecting to phabricator on this machine.
Apologies! I hope it's OK for such a small fix.

Jul 16 2018, 3:24 AM
sgraf created D4969: Fix a major copy'n'paste error in LLVM CodeGen.
Jul 16 2018, 3:22 AM
sgraf added a comment to rGHC6243bba73d14: Add 'addWordC#' PrimOp.

I have a concern about the LLVM implementation. using *usub*, while the primop name suggests it should be *uadd*.
b
if *usub* is correct, we should add a note?

Jul 16 2018, 2:10 AM

Apr 25 2018

sgraf added a comment to D4592: Add 'addWordC#' PrimOp.

This looks reasonable. However, we should add an entry to ghc-prim's changelog mentioning the addition. Moreover, we should perhaps add an entry for this in the release notes.

Apr 25 2018, 7:42 AM

Apr 23 2018

sgraf updated the diff for D4592: Add 'addWordC#' PrimOp.
  • Replaced all occurrences of ghc-prim-0.5.2.0 by ghc-prim-0.5.2.1
Apr 23 2018, 3:18 PM

Apr 22 2018

sgraf updated the diff for D4592: Add 'addWordC#' PrimOp.
  • Make ghc-compact play with ghc-prim-0.5.2.1
Apr 22 2018, 7:18 AM
sgraf updated the diff for D4592: Add 'addWordC#' PrimOp.

Push to staging

Apr 22 2018, 6:11 AM

Apr 20 2018

sgraf added a comment to D4592: Add 'addWordC#' PrimOp.

OK, I just pushed an update with --skip-staging (my setup here is still broken) that reverted the accidental update that was meant for D4605 and also added updates to 8.6.1-notes.rst, ghc-prim/changelog.md and ghc-prim/ghc-prim.cabal (the last three files of the diff). Is that enough for release notes or did I miss something?

Apr 20 2018, 4:16 AM
sgraf updated the diff for D4592: Add 'addWordC#' PrimOp.
  • Bumped ghc-prim to 0.5.2.1
  • Updated changelogs of ghc-prim and 8.6.1
Apr 20 2018, 4:16 AM
sgraf added a parent revision for D4605: Algebraically simplify add/sub with carry/overflow: D4592: Add 'addWordC#' PrimOp.
Apr 20 2018, 2:53 AM
sgraf added a child revision for D4592: Add 'addWordC#' PrimOp: D4605: Algebraically simplify add/sub with carry/overflow.
Apr 20 2018, 2:53 AM
sgraf added a comment to D4605: Algebraically simplify add/sub with carry/overflow.

Note that this needs D4592 to land first.

Apr 20 2018, 2:15 AM
sgraf added a comment to D4592: Add 'addWordC#' PrimOp.

Is there a way I can revert the last update to a differential?

Apr 20 2018, 2:15 AM
sgraf updated the diff for D4605: Algebraically simplify add/sub with carry/overflow.
  • Algebraically simplify add/sub with carry/overflow
  • Comments for identity rules
Apr 20 2018, 2:15 AM
sgraf added a comment to D4592: Add 'addWordC#' PrimOp.

God damn it! That arc diff should have pushed to D4605

Apr 20 2018, 2:15 AM
sgraf updated the diff for D4592: Add 'addWordC#' PrimOp.
  • Algebraically simplify add/sub with carry/overflow
  • Comments for identity rules
Apr 20 2018, 2:15 AM
sgraf planned changes to D4547: Fix inlining of 'c' in efdt{Int,Word}{Up,Dn}FB.

Yeah, this is not yet ready to merge. See https://ghc.haskell.org/trac/ghc/ticket/8763#comment:58, this version will still duplicate c if it can't constant fold away the up or down decision in eftdIntFB.

Apr 20 2018, 2:01 AM

Apr 18 2018

sgraf added reviewers for D4605: Algebraically simplify add/sub with carry/overflow: simonpj, hsyl20.
Apr 18 2018, 4:58 PM
sgraf requested review of D4605: Algebraically simplify add/sub with carry/overflow.
Apr 18 2018, 1:38 AM

Apr 17 2018

sgraf added a comment to D4565: Add a test case from the nested CPR work.

Does this pass without the nested CPR patch being merged?

Apr 17 2018, 10:47 AM

Apr 13 2018

sgraf added inline comments to D4592: Add 'addWordC#' PrimOp.
Apr 13 2018, 1:12 PM
sgraf added inline comments to D4592: Add 'addWordC#' PrimOp.
Apr 13 2018, 1:12 PM

Apr 12 2018

sgraf abandoned D4563: Add strict product field demands to lambda binders.
Apr 12 2018, 9:22 AM

Apr 10 2018

sgraf abandoned D4574: Make `catch` and `catchException` no longer strict in their first argument.
Apr 10 2018, 10:36 AM
sgraf added a comment to D4574: Make `catch` and `catchException` no longer strict in their first argument.

I'm now pretty much opposed to making this change. Thanks for letting me think twice!

Apr 10 2018, 4:05 AM
sgraf added a comment to D4574: Make `catch` and `catchException` no longer strict in their first argument.

Over in Trac #14998 I had some revelations about how things ought to go together.

Apr 10 2018, 3:50 AM

Apr 6 2018

sgraf requested review of D4574: Make `catch` and `catchException` no longer strict in their first argument.

Relevant part of the thread.

Apr 6 2018, 9:00 AM
sgraf requested review of D4573: Declare `catchRetry#` lazy in its first argument.

https://ghc.haskell.org/trac/ghc/ticket/14998#comment:8 talks about this diff.

Apr 6 2018, 8:50 AM
sgraf requested review of D4547: Fix inlining of 'c' in efdt{Int,Word}{Up,Dn}FB.

See #8763 for numbers.

Apr 6 2018, 3:16 AM
sgraf requested review of D4565: Add a test case from the nested CPR work.
Apr 6 2018, 2:58 AM

Apr 3 2018

sgraf added a comment to D4244: Nested CPR.

Added a few explanations where I could. I'm not sure I really understand everything in this diff, so we maybe should try some changes in isolation, as @simonpj suggested? Then we can rebase this based on those changes.

Apr 3 2018, 8:53 AM

Mar 22 2018

sgraf added a comment to D4519: Create stronger ArgOccs from calls to specialized functions.

Sorry for the early shot: I had another look at the 'unification algorithm' and found something to discuss.

Mar 22 2018, 12:27 PM
sgraf added a comment to D4519: Create stronger ArgOccs from calls to specialized functions.

Code LGTM. Although this would profit from a more general unification function on CallPats and/or CoreRules, but we currently don't have one.

Mar 22 2018, 12:17 PM

Jan 6 2018

sgraf added a comment to D4244: Nested CPR.

These are the NoFib results counting instructions with cachegrind:

Jan 6 2018, 4:53 AM

Dec 27 2017

sgraf updated the diff for D4244: Nested CPR.
  • Elaborated Note [Termination information and arguments]
  • More in-depth inline description of CPRResult
Dec 27 2017, 4:34 PM