Skip to content

Conversation

dan-zheng
Copy link
Collaborator

@dan-zheng dan-zheng commented Apr 4, 2023

Main changes:


Status: work-in-progress.

  • make now works on Apple M1.
    • The easiest path to Apple M1 support I found involved upgrading both GHC (details) and LLVM.
  • make unit-tests passes.
  • Fix compiler warnings (full log).
    • There are many -Wincomplete-uni-patterns warnings because -Wincomplete-uni-patterns was added to -Wall in GHC 9.2.1 (source).
  • make tests passes.

Fixes #1247.

@dan-zheng dan-zheng mentioned this pull request Apr 4, 2023
@dan-zheng dan-zheng force-pushed the llvm-15 branch 20 times, most recently from 9edb341 to 7cd1c47 Compare April 5, 2023 13:14
@dan-zheng dan-zheng force-pushed the llvm-15 branch 9 times, most recently from aeee683 to 5a49aa5 Compare April 12, 2023 07:24
@dan-zheng dan-zheng force-pushed the llvm-15 branch 11 times, most recently from 6de7bf5 to 573bdfe Compare April 12, 2023 19:18
@dan-zheng dan-zheng force-pushed the llvm-15 branch 4 times, most recently from 8a5c65f to 5a0ee63 Compare April 12, 2023 23:29
@dan-zheng dan-zheng requested a review from dougalm April 13, 2023 15:16
@dan-zheng
Copy link
Collaborator Author

I believe this is ready for review now. @dougalm

Let me know if I should do anything else!

dan-zheng added 4 commits May 19, 2023 13:08
- Upgrade to GHC 9.2.x.
  - Apple M1 support seems to be mostly mature starting in GHC 9.2.1:
    https://www.haskell.org/ghc/blog/20210309-apple-m1-story.html.
- Upgrade to LLVM 15.
  - Use the same resolver in stack*.yaml files as llvm-hs:llvm-15 for
    consistency.

`make` now works on Apple M1, albeit with compiler warnings, some of which seem
significant.
Fix warnings, namely -Wstar-is-type.

Many -Wincomplete-uni-patterns warnings are not yet fixed.
`diff` on macOS does not support the `--left-column` flag.

Use `sdiff` (side-by-side diff) instead, which is part of diffutils.
- Fix dependency versions in stack.yaml.
- Fix dependency installation (`install_deps`) in haskell-ci.yaml and
  python-ci.yaml.
- Run pytest with `-v` to show testcase names, for easier debugging.
@dan-zheng dan-zheng force-pushed the llvm-15 branch 2 times, most recently from 6802485 to e542739 Compare May 19, 2023 21:23
dan-zheng added 3 commits May 19, 2023 15:35
Fix all warnings except `-Wincomplete-uni-patterns` and `-Wincomplete-record-updates`,
which were newly added to `-Wall` (starting in GHC 9.2.1).

https://github.com/ghc-proposals/ghc-proposals/blob/master/proposals/0071-Wall-uni-patterns.rst
- Update `llvm.memcpy` and `llvm.memset` intrinsic name mangling to use `p0`
  instead of `p0i8` as the pointer type.
  - https://releases.llvm.org/15.0.0/docs/LangRef.html#llvm-memcpy-intrinsic
- Update expected numerical values in various tests.
- Mark and disable failing tests with `FIXME(llvm-15)`.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Building on M1 Mac

2 participants