Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

macOS Metal + AppKit app #2205

Merged
merged 41 commits into from Apr 1, 2024
Merged

macOS Metal + AppKit app #2205

merged 41 commits into from Apr 1, 2024

Conversation

louwers
Copy link
Collaborator

@louwers louwers commented Mar 18, 2024

  • Remove unused macOS scripts.
  • Add Bazel targets for macOS (main toolkit, AppKit app, GLFW app, cache tool, render tool)
  • Update CI to build macOS (no tests yet).
  • Switch to libuv instead of CFRunLoop on macOS.
  • Modify .clang-format to make pre-commit happy. I can maybe apply Objective-C formatting to the entire codebase in a later PR.
  • Updated Bazel.
  • Improved config handling.
    • The config is shared between macOS and iOS
    • Location: platform/darwin/bazel/config.bzl
    • By default, the example config is used. This is useful for including this repo in another Bazel workspace.

I would like to get this merged because it's already getting quite a big change. To be addressed later:

  • TODO: the AppKit app probably had it's own run loop, because it's missing one now. We need to either:
    • Get the CFRunLoop working (again) under macOS, or:
    • Kick off the libuv based run loop on macOS AppKit
  • TODO: GLFW Bazel build for other platforms?
  • TODO:: re-use platform/glfw/metal_backend.mm for other platforms (Qt, Node.js?) move to platform/darwin

@louwers louwers added metal build Related to build, configuration or CI/CD macOS github_actions Pull requests that update GitHub Actions code labels Mar 18, 2024
Copy link

github-actions bot commented Mar 18, 2024

Bloaty Results 🐋

Compared to main

    FILE SIZE        VM SIZE    
 --------------  -------------- 
  [ = ]       0  +0.0%     +16    TOTAL

Full report: https://maplibre-native.s3.eu-central-1.amazonaws.com/bloaty-results/pr-2205-compared-to-main.txt

Compared to d387090 (legacy)

    FILE SIZE        VM SIZE    
 --------------  -------------- 
   +20% +23.1Mi  +406% +24.3Mi    TOTAL

Full report: https://maplibre-native.s3.eu-central-1.amazonaws.com/bloaty-results/pr-2205-compared-to-legacy.txt

Copy link

github-actions bot commented Mar 18, 2024

Benchmark Results ⚡

Benchmark                                                     Time             CPU      Time Old      Time New       CPU Old       CPU New
------------------------------------------------------------------------------------------------------------------------------------------
OVERALL_GEOMEAN                                            -0.0019         -0.0014             0             0             0             0

Full report: https://maplibre-native.s3.eu-central-1.amazonaws.com/benchmark-results/pr-2205-compared-to-main.txt

@louwers louwers marked this pull request as ready for review March 28, 2024 14:00
@louwers louwers requested a review from mwilsnd March 28, 2024 14:00
Copy link

github-actions bot commented Apr 1, 2024

Bloaty Results (iOS) 🐋

Compared to main

    FILE SIZE        VM SIZE    
 --------------  -------------- 
  [ = ]       0  [ = ]       0    TOTAL

Full report: https://maplibre-native.s3.eu-central-1.amazonaws.com/bloaty-results-ios/pr-2205-compared-to-main.txt

@louwers louwers merged commit e4a4b9e into maplibre:main Apr 1, 2024
32 checks passed
@louwers louwers deleted the macos-metal branch April 1, 2024 23:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
build Related to build, configuration or CI/CD github_actions Pull requests that update GitHub Actions code macOS metal
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants