Posts by stevestreza@mastodon.social
(DIR) Post #ANLHjuoL9165Zqk652 by stevestreza@mastodon.social
2022-09-08T03:32:02Z
0 likes, 0 repeats
Finally got some shared timing stuff hooked up, and without any profiling or optimization and while being a complete Rust newbie, this thing is already running at 18 MHz, well above the 4 MHz needed by the Master System.When I tried to build a Game Boy emulator in Swift, the performance was probably 100x slower by default, and needed a lot of tuning and measuring to get past the 4 MHz mark.
(DIR) Post #ANMTfRS9kOXbyWxXw8 by stevestreza@mastodon.social
2022-09-08T06:07:11Z
1 likes, 0 repeats
@shadowfacts Swift does try to hide a lot of implementation detail from you, which makes it good for apps but less good for systems programming, so it's not a surprise that it's easier to write high-throughput code by default in a language like Rust. Probably also why Swift is moving in that direction.
(DIR) Post #ANSNXj3QzMU3TI5pGy by stevestreza@mastodon.social
2022-09-11T07:27:19Z
1 likes, 0 repeats
Not as easy as I would've liked but I have a working setup where Rust crate builds into static library into manually written Swift adapter package into Mac/iOS app. Resulting Mac app binary (x86_64 + aarm64) is only 2.3 MB.
(DIR) Post #ANSNXkbrCrc4ILCpZA by stevestreza@mastodon.social
2022-09-11T07:32:43Z
0 likes, 0 repeats
This should enable having a shared Rust core of data structures and business logic that can be bridged into basically any platform, and a native UI can be derived from library calls that are exposed to it. This covers Mac and iOS, Rust itself can be used to build Linux apps, so next would be writing adapters for Kotlin/Java on Android and … whatever you use to build Windows apps these days.
(DIR) Post #ANSfIbsnAWti3n3bM0 by stevestreza@mastodon.social
2022-09-11T16:52:03Z
1 likes, 0 repeats
@shadowfacts There's a Rust BeamoClient and a Swift BeamoClient, they have no knowledge of each other. The business logic is implemented in Rust, which doesn't really interact with Swift (though hopefully there can be a little through things like callbacks).Here's the fuller code, but renamed those types to RustBeamoClient and SwiftBeamoClient. https://gist.github.com/stevestreza/80f11d095c024743281de9de0be5432d
(DIR) Post #ANSkSfieG9k0covha4 by stevestreza@mastodon.social
2022-09-11T18:07:42Z
1 likes, 0 repeats
@shadowfacts A great question that I should probably figure out the answer to, huh
(DIR) Post #ANSpn1yRj4QLD3qWoq by stevestreza@mastodon.social
2022-09-11T18:41:16Z
0 likes, 0 repeats
@shadowfacts Probably for the best, if the goal is to make a memory safe language, you can't really assume anything about that String beyond the lifetime of that initializer without copying.
(DIR) Post #ANT1ZjdzlOuQ2uhtiK by stevestreza@mastodon.social
2022-09-11T19:25:49Z
0 likes, 0 repeats
@shadowfacts It may have ultimately been a lie due to NSString bridging: https://forums.swift.org/t/does-string-bytesnocopy-copy-bytes/51643
(DIR) Post #ANUmkyZ2x6oh5JSVs0 by stevestreza@mastodon.social
2022-09-12T08:19:37Z
1 likes, 0 repeats
Me: Ok I, a complete Rust newbie, have a working Rust bridge to C/Swift, so let me try to get it to do some async multi-threaded stuff in Rust with a callback to Swift.Rust and the Send trait:
(DIR) Post #ANYwsLYmDpZYrPNxzM by stevestreza@mastodon.social
2022-09-14T08:00:21Z
1 likes, 0 repeats
Starting to really get into a good flow with Rust where the compiler is helping me fix problems faster than I would on my own, and not just consisting of me fighting it. Even starting to get a little bolder with reference lifetimes and using &str instead of always defaulting to String.
(DIR) Post #ANenfM5ozsJ3XO5s6y by stevestreza@mastodon.social
2022-09-17T08:43:38Z
1 likes, 0 repeats
Past me: Time to learn Rust by writing an end-to-end-encrypted peer-to-peer file transfer system before thinking about the complexity of any of those termsCurrent me: why
(DIR) Post #AOLPZsbGsqSJwgwIl6 by stevestreza@mastodon.social
2022-10-08T03:06:26Z
0 likes, 0 repeats
Why am I picking up re-follows today
(DIR) Post #AOYn5DHjhar3vE3w92 by stevestreza@mastodon.social
2022-10-14T08:15:22Z
1 likes, 0 repeats
In the modern age where everything is either free but steals your data OR only available via predatory subscription models, any moral qualms I had with piracy have basically evaporated for content that is only available via these services. In many cases it is now the only actual means of archival, and we are already seeing companies burn their libraries to the ground.
(DIR) Post #AP0qzwhxhvswll4EQC by stevestreza@mastodon.social
2022-10-28T02:31:10Z
0 likes, 0 repeats
I really gotta write that "fediverse server for one person" at some point.
(DIR) Post #AP0rK1v82PAsj7npIG by stevestreza@mastodon.social
2022-10-28T03:00:08Z
1 likes, 0 repeats
@shadowfacts I love it when people do the work for me!
(DIR) Post #AP0u4oKOakae5b3Vey by stevestreza@mastodon.social
2022-10-28T02:59:15Z
1 likes, 0 repeats
I'm Steve, a 35 year old programmer in Seattle. My day job is building iOS apps (currently Teams, previously Tumblr and Pocket). At home I tinker with streaming tools for my partner, fandom convention tools, Mac/Linux desktop/mobile apps, web services, microcontroller projects, and whatever else inspires.Beyond code I do 3D modeling/printing, woodworking, synthesizers, comic writing, helping run my partner's merch business, and playing FFXIV and logistics sim games.#introduction
(DIR) Post #AP4n9p3xMgHClleHpI by stevestreza@mastodon.social
2022-10-29T22:37:54Z
1 likes, 0 repeats
Not many movies bring me sheer joy when watching them like Knives Out.
(DIR) Post #AP6qkG3hA25n6CVn1s by stevestreza@mastodon.social
2022-10-30T20:30:38Z
1 likes, 0 repeats
On top of making a terribly designed and implemented product, I am completely non-surprised to learn that their fraud prevention is dogshit as well. I've been banned 6 times in the last two weeks, and every time support says "nothing is wrong, it was in error, your account is reactivated in 2 hours", and then I wait until the next day (since they make a FOOD PRODUCT so waiting two hours is a non-option) to reorder... and then I get banned again. Clown operation.
(DIR) Post #AP8495Vszwu8C9pOD2 by stevestreza@mastodon.social
2022-10-31T02:52:38Z
1 likes, 0 repeats
@shadowfacts it's been chugging today
(DIR) Post #APGpgdshRx14zIUv0C by stevestreza@mastodon.social
2022-11-04T19:04:33Z
0 likes, 0 repeats
📢 MOVING INSTANCES 📢I am moving to @stevestreza@indieweb.social! 🎉 A huge thank you to mastodon.social for hosting me over the years. My old toots shall remain here indefinitely barring some reason to make them inactive.The migration *should* make this transition seamless but I would deeply appreciate checking to see if you follow @stevestreza@indieweb.social in a few hours/days. Thank you all very much for the follows 😊