Skip to content

Instantly share code, notes, and snippets.

@heckj
heckj / benchmark-comparison.md
Created October 10, 2024 20:17
FirebladeECS value types benchmarking

Benchmarking switching FirebladeECS to use value types

Comparing results between branch master and the first commit from fireblade-engine/ecs#47 (2b51eeea6e379d4c66e04dc9103b199886993694)

Host 'MacBookPro' with 8 'arm64' processors with 16 GB memory, running:
Darwin Kernel Version 24.0.0: Tue Sep 24 23:36:26 PDT 2024; root:xnu-11215.1.12~1/RELEASE_ARM64_T8103

ECSBenchmark

Swift Project

cd ~/src/swift-project/swift
./utils/update-checkout --clone-with-ssh --clean

Base build

sccache --start-server
Translated Report (Full Report Below)
-------------------------------------
Process: Safari [2490]
Path: /Volumes/VOLUME/*/Safari.app/Contents/MacOS/Safari
Identifier: com.apple.Safari
Version: 16.5 (18615.2.9.11.4)
Build Info: Safari-7615002009011004~2
Code Type: ARM-64 (Native)
Parent Process: launchd [1]
Building with settings:
USD source directory /Users/heckj/src/USD
USD install directory /opt/local/USD
3rd-party source directory /opt/local/USD/src
3rd-party install directory /opt/local/USD
Build directory /opt/local/USD/build
CMake generator Default
CMake toolset Default
Downloader curl
@heckj
heckj / FormAndVStackExample.swift
Created July 12, 2022 20:57
SwiftUI contextual rendering example
// Content expanded from Form reference documentation at
// https://developer.apple.com/documentation/swiftui/form
import SwiftUI
enum ProfileImageSize {
case large
case medium
case small
}
<unknown>:0: error: fatal error encountered while reading from module 'OrderedCollections'; please file a bug report with your project and the crash log
<unknown>:0: note: module 'OrderedCollections' full misc version is '5.3.2(5.3.2)/Apple Swift version 5.3.2 (swiftlang-1200.0.45 clang-1200.0.32.28)'
*** DESERIALIZATION FAILURE (please include this section in any bug report) ***
result not found
Cross-reference to module 'OrderedCollections'
... OrderedSet
... in an extension in module 'OrderedCollections'
... Element
#! /usr/bin/swift
//
// - This is just some AppKit boilerplate to launch a window.
//
import AppKit
@available(OSX 10.15, *)
class AppDelegate: NSObject, NSApplicationDelegate {
let window = NSWindow()
let windowDelegate = WindowDelegate()
import * as opentracing from 'opentracing';
import { DocumentQuery } from 'mongoose';
// Notes and light documentation at <https://github.com/jaegertracing/jaeger-client-node>
// templates for running Jaeger pieces in Kubernetes at <https://github.com/jaegertracing/jaeger-kubernetes>
// If you're working in local development and want to see what's up here, you can run a local instance
// of Jaeger in a docker container to capture any generated traces locally. This works with running the
// unit tests and traces they generate.
//
@heckj
heckj / Capsule.swift
Created April 21, 2019 15:22
A Reusable SCNNode SubClass With An SCNCapsule Geometry
//
// Capsule.swift
//
//
// Created by Josh Robbins on 24/02/2018.
// Copyright © 2018 BlackMirror. All rights reserved.
//
import Foundation
import SceneKit