[Git][ghc/ghc][wip/az/locateda-epa-improve-2023-07-15] 46 commits: Simplify and correct nasty case in coercion opt

Alan Zimmerman (@alanz) gitlab at gitlab.haskell.org
Thu Oct 12 22:20:54 UTC 2023



Alan Zimmerman pushed to branch wip/az/locateda-epa-improve-2023-07-15 at Glasgow Haskell Compiler / GHC


Commits:
bc204783 by Richard Eisenberg at 2023-10-02T14:50:52+02:00
Simplify and correct nasty case in coercion opt

This fixes #21062.

No test case, because triggering this code seems challenging.

- - - - -
9c9ca67e by Andrew Lelechenko at 2023-10-04T05:42:28-04:00
Bump bytestring submodule to 0.12.0.2

- - - - -
4e46dc2b by Andrew Lelechenko at 2023-10-04T05:42:28-04:00
Inline bucket_match

- - - - -
f6b2751f by Ben Gamari at 2023-10-04T05:43:05-04:00
configure: Fix #21712 again

This is a bit of a shot in the dark to fix #24033, which appears to be
another instance of #21712. For some reason the ld-override logic
*still* appears to be active on Darwin targets (or at least one).
Consequently, on misconfigured systems we may choose a non-`ld64`
linker.

It's a bit unclear exactly what happened in #24033 but ultimately the
check added for #21712 was not quite right, checking for the
`ghc_host_os` (the value of which depends upon the bootstrap compiler)
instead of the target platform. Fix this.

Fixes #24033.

- - - - -
2f0a101d by Krzysztof Gogolewski at 2023-10-04T05:43:42-04:00
Add a regression test for #24029

- - - - -
8cee3fd7 by sheaf at 2023-10-04T05:44:22-04:00
Fix non-symbolic children lookup of fixity decl

The fix for #23664 did not correctly account for non-symbolic names
when looking up children of a given parent. This one-line fix changes
that.

Fixes #24037

- - - - -
a4785b33 by Cheng Shao at 2023-10-04T05:44:59-04:00
rts: fix incorrect ticket reference

- - - - -
e037f459 by Ben Gamari at 2023-10-04T05:45:35-04:00
users-guide: Fix discussion of -Wpartial-fields

 * fix a few typos
 * add a new example showing when the warning fires
 * clarify the existing example
 * point out -Wincomplete-record-selects

Fixes #24049.

- - - - -
8ff3134e by Matthew Pickering at 2023-10-05T05:34:58-04:00
Revert "Pass preprocessor options to C compiler when building foreign C files (#16737)"

This reverts commit 1c18d3b41f897f34a93669edaebe6069f319f9e2.

`-optP` should pass options to the preprocessor, that might be a very
different program to the C compiler, so passing the options to the C
compiler is likely to result in `-optP` being useless.

Fixes #17185 and #21291

- - - - -
8f6010b9 by Ben Gamari at 2023-10-05T05:35:36-04:00
rts/nonmoving: Fix on LLP64 platforms

Previously `NONMOVING_SEGMENT_MASK` and friends were defined with the `UL`
size suffix. However, this is wrong on LLP64 platforms like Windows,
where `long` is 32-bits.

Fixes #23003.
Fixes #24042.

- - - - -
f20d02f8 by Andreas Klebinger at 2023-10-05T05:36:14-04:00
Fix isAArch64Bitmask for 32bit immediates.

Fixes #23802

- - - - -
63afb701 by Bryan Richter at 2023-10-05T05:36:49-04:00
Work around perf note fetch failure

Addresses #24055.

- - - - -
242102f4 by Krzysztof Gogolewski at 2023-10-05T05:37:26-04:00
Add a test for #21348

- - - - -
7d390bce by Rewbert at 2023-10-05T05:38:08-04:00
Fixes #24046

- - - - -
69abb171 by Finley McIlwaine at 2023-10-06T14:06:28-07:00
Ensure unconstrained instance dictionaries get IPE info

In the `StgRhsCon` case of `GHC.Stg.Debug.collectStgRhs`, we were not coming up
with an initial source span based on the span of the binder, which was causing
instance dictionaries without dynamic superclass constraints to not have source
locations in their IPE info. Now they do.

Resolves #24005

- - - - -
390443b7 by Andreas Klebinger at 2023-10-07T10:00:20-04:00
rts: Split up rts/include/stg/MachRegs.h by arch

- - - - -
3685942f by Bryan Richter at 2023-10-07T10:00:56-04:00
Actually set hackage index state

Or at least, use a version of the cabal command that *claims* to set the
index state.

Time will tell.

- - - - -
46a0e5be by Bryan Richter at 2023-10-07T10:00:56-04:00
Update hackage index state

- - - - -
d4b037de by Bryan Richter at 2023-10-07T10:00:56-04:00
Ensure hadrian uses CI's hackage index state

- - - - -
e206be64 by Andrew Lelechenko at 2023-10-08T15:06:14-04:00
Do not use O_NONBLOCK on regular files or block devices

CLC proposal https://github.com/haskell/core-libraries-committee/issues/166

- - - - -
a06197c4 by David Binder at 2023-10-08T15:06:55-04:00
Update hpc-bin submodule to 0.69

- - - - -
ed6785b6 by David Binder at 2023-10-08T15:06:55-04:00
Update Hadrian with correct path to happy file for hpc-bin

- - - - -
94066d58 by Alan Zimmerman at 2023-10-09T21:35:53-04:00
EPA: Introduce HasAnnotation class

The class is defined as

    class HasAnnotation e where
      noAnnSrcSpan :: SrcSpan -> e

This generalises noAnnSrcSpan, and allows

    noLocA :: (HasAnnotation e) => a -> GenLocated e a
    noLocA = L (noAnnSrcSpan noSrcSpan)

- - - - -
8792a1bc by Ben Gamari at 2023-10-09T21:36:29-04:00
Bump unix submodule to v2.8.3.0

- - - - -
61ca0891 by Alan Zimmerman at 2023-10-10T18:43:46+01:00
EPA Some tweaks to annotations

- Fix span for GRHS
- Move TrailingAnns from last match to FunBind
- Fix GADT where clause span
- Capture full range for a CaseAlt Match

info: patch template saved to `-`

- - - - -
035778e7 by Alan Zimmerman at 2023-10-11T21:28:45+01:00
EPA: Use full range for Anchor

EPA Use full range for Anchor, and do not widen for [TrailingAnn]

Known failures at the end of this
  Ppr023
  Ppr034
  TestBoolFormula

Fixed in subsequent commits

EPA: Use the current Anchor end as prior end

Use the original anchor location end as the source of truth for
calculating print deltas.

This allows original spacing to apply in most cases, only changed AST
items need initial delta positions.

[2023-08-14 Mon]
121 unexpected failures

EPA: Add DArrow to TrailingAnn

[EPA] Introduce HasTrailing in ExactPrint

29 Failing tests by 4600 processed

info: patch template saved to `-`

EPA use [TrailingAnn] in enterAnn

And remove it from ExactPrint (LocatedN RdrName)

Summary: Patch:  epa-in-hsdo-put-trailinganns
Author: Alan Zimmerman <alan.zimm at gmail.com>
Date:   2023-07-03 22:33:49 +0100

EPA: In HsDo, put TrailingAnns at top of LastStmt

Failures
5300 of 9700 [0, 103, 0]

EPA: do not convert comments to deltas when balancing.

It seems its not needed with the new approach

[2023-08-15 Tue]
104 unexpected failures

EPA: deal with fallout from getMonoBind

EPA fix captureLineSpacing

EPA print any comments in the span before exiting it

EPA: getting rid of tweakDelta

WIP at present

EPA: tweaks to ExactPrint

EPA: Fix warnings in check-exact

EPA: Add comments to AnchorOperation

6000 of 9700 [0, 14, 0]
Failures seem to be mainly in transform tests

EPA: remove AnnEofComment

It is no longer used

At this point just failures
  HsDocTy

[2023-08-31 Thu]
And no warnings in check-exact

info: patch template saved to `-`

- - - - -
a25678d9 by Alan Zimmerman at 2023-10-11T21:28:58+01:00
EPA: make locA a function, not a field name

- - - - -
a3c74211 by Alan Zimmerman at 2023-10-11T21:28:58+01:00
EPA: generalise reLoc

[2023-10-01 Sun]
Failures
   HsDocTy

- - - - -
1e5ac621 by Alan Zimmerman at 2023-10-11T21:28:59+01:00
EPA: get rid of l2l and friends

- - - - -
e67a5c9f by Alan Zimmerman at 2023-10-11T21:28:59+01:00
EPA: get rid of l2l and friends

- - - - -
f58d81ca by Alan Zimmerman at 2023-10-11T21:28:59+01:00
EPA: harmonise acsa and acsA

[2023-10-01 Sun]
Failing tests
  HsDocTy

- - - - -
d348cd16 by Alan Zimmerman at 2023-10-11T22:13:52+01:00
EPA: Replace Anchor with EpaLocation

[2023-09-21 Thu]
Only test failing is
   HsDocTy

- - - - -
ba1142c4 by Alan Zimmerman at 2023-10-11T22:13:57+01:00
EPA: get rid of AnchorOperation

[2023-09-21 Thu]
Only error is
  HsDocTy

- - - - -
879cc2f1 by Alan Zimmerman at 2023-10-11T22:13:57+01:00
EPA: splitLHsForAllTyInvis no ann returned

- - - - -
aee6f171 by Alan Zimmerman at 2023-10-11T22:13:57+01:00
EPA: Replace Monoid with NoAnn

[2023-08-19 Sat]
AddClassMethod fails

- - - - -
9c53bbea by Alan Zimmerman at 2023-10-11T23:14:44+01:00
EPA: Use SrcSpan in EpaSpan

[2023-09-04 Mon]
No errors or warnings in check-exact

[2023-09-21 Thu]
Test failures
   HsDocTy

- - - - -
7012f66c by Alan Zimmerman at 2023-10-11T23:14:48+01:00
EPA: Present no longer has annotation

- - - - -
5be53a08 by Alan Zimmerman at 2023-10-11T23:14:48+01:00
EPA: empty tup_tail has no ann

Parser.y: tup_tail rule was
          | {- empty -} %shift   { return [Left noAnn] }

This means we add an extra Missing constructor if the last item was a comma.

Change the annotation type to a Bool to indicate this, and use the
EpAnn Anchor for the print location for the others.

- - - - -
671bef2c by Alan Zimmerman at 2023-10-11T23:14:49+01:00
EPA: Remove parenthesizeHsType

- - - - -
a304291c by Alan Zimmerman at 2023-10-12T18:29:46+01:00
EPA: Remove EpAnnNotUsed

[2023-10-01 Sun]
Failures
  HsDocTy
  T15242

- - - - -
a56e8e06 by Alan Zimmerman at 2023-10-12T20:53:36+01:00
EPA: Remove SrcSpanAnn

[2023-10-12 Thu]
  Failures
    HsDocTy
    T15242

- - - - -
591f129d by Alan Zimmerman at 2023-10-12T21:51:15+01:00
EPA: Remove SrcSpanAnn completely

- - - - -
f7bb637d by Alan Zimmerman at 2023-10-12T21:51:23+01:00
Clean up mkScope

- - - - -
a0909978 by Alan Zimmerman at 2023-10-12T21:51:24+01:00
EPA: Clean up TC Monad Utils

- - - - -
ce741cb3 by Alan Zimmerman at 2023-10-12T21:51:24+01:00
EPA: EpaDelta for comment has no comments

[2023-09-23 Sat]
Current failures
   HsDocTy
   T15242

- - - - -
d847e83e by Alan Zimmerman at 2023-10-12T23:20:20+01:00
Semigroup instances for AnnList and AnnContext

- - - - -


26 changed files:

- .gitignore
- .gitlab/ci.sh
- .gitlab/test-metrics.sh
- compiler/CodeGen.Platform.h
- compiler/GHC/CmmToAsm.hs
- compiler/GHC/CmmToAsm/AArch64/CodeGen.hs
- compiler/GHC/Core/Coercion.hs
- compiler/GHC/Core/Coercion/Opt.hs
- compiler/GHC/Data/FastString.hs
- compiler/GHC/Driver/Pipeline/Execute.hs
- compiler/GHC/Hs.hs
- compiler/GHC/Hs/Binds.hs
- compiler/GHC/Hs/Decls.hs
- compiler/GHC/Hs/Dump.hs
- compiler/GHC/Hs/Expr.hs
- compiler/GHC/Hs/Extension.hs
- compiler/GHC/Hs/ImpExp.hs
- compiler/GHC/Hs/Pat.hs
- compiler/GHC/Hs/Type.hs
- compiler/GHC/Hs/Utils.hs
- compiler/GHC/HsToCore/Arrows.hs
- compiler/GHC/HsToCore/Docs.hs
- compiler/GHC/HsToCore/Monad.hs
- compiler/GHC/Iface/Ext/Ast.hs
- compiler/GHC/Iface/Ext/Utils.hs
- compiler/GHC/Parser.y


The diff was not included because it is too large.


View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/d035f64f27874c44ab1422ebe348b5f601f04dda...d847e83e7ddd6e3aa0be83cb40636fab0a5b10f0

-- 
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/d035f64f27874c44ab1422ebe348b5f601f04dda...d847e83e7ddd6e3aa0be83cb40636fab0a5b10f0
You're receiving this email because of your account on gitlab.haskell.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/ghc-commits/attachments/20231012/49da38c8/attachment-0001.html>


More information about the ghc-commits mailing list