šŸ™Œ inaugural microblog post! sp1'23, week 10, day 2

Inaugural microblog post (implemented today)!

breakfast: crusty bread with vegan butter and marionberry jam šŸ¤ÆšŸ˜‹ plus coffee

minimum viable code 10-11am

(reminder to my otherly-timezoned batchmates who attend my events: Iā€™m in pacific time)

hosted MVC with 4 others in attendance. my usual format, as usual:

(TODO: I need to write up a blog post or RC wiki page describing my style of running an accountability event that punchily maximizes engagement for distractible people)

continued working through rustwasm tutorial

I fixed a bug I got stuck on yesterday in my rustwasm game of life web renderer which displays in JS but interops with Rust (where the game logic runs) via WebAssembly. The game logic itself is straightforward but there are a lot of Rust subtleties in here that I definitely donā€™t understand, and need to go back through.

Also added a speed control and a reset button.

game of life gif

dev journal notes

now what

From a WASM interop perspective, here are the steps the tutorial goes through.

  1. Naive game of life implementation. Pass the entire game state to JS each time, just to get basic interop working.
  2. Pointer access into WASMā€™s linear memory. JS holds a pointer to the spot in memory where the game state is stored. Rust modifies the state and JS peeks at the state.
  3. Cell state is simply true or false, so save space by switching from bytes (8 bits) to bits.

I just finished step 2 and havenā€™t started step 3 yet.

Unfortunately, although step 3 seems wildly useful from a learning perspective, I feel viscerally unmotivated to continue from a practical perspective because there are no true performance-pushing constraints in this toy exercise. Even the naive implementation was so blazing fast that each universe step-and-re-render is being completed in a few milliseconds, way faster FPS than my human brain is capable of perceiving, and I highly suspect the bulk of that time is on the display side. I even had to add a slider to slow down the rendering so I could perceive it.

In the interest of tricking my motivational system into wanting to do this AND going back to better understand more subtleties of the Rust code I am rather blindly using, I think it might be fun to add runtime/memory profiling and write up a comparison between the three approaches.

Then, I got distracted by a different idea: microblogging.

add a microblog to my blog

Many recursers post daily journal entries, which are cute and fun. I always feel better and more self-connected on days I remembered to write a daily checkin because it takes me from the ā€œugh I didnā€™t get anything doneā€ mindset to the ā€œoh shit I actually did a lot of thingsā€ truth.

in summary: 1.5 hrs of actual project code, 2 hrs of blog feature implementation, and 1.5 hrs of blogging about what I did today šŸ¤£

fun asides

FYI, I look up emoji in my terminal via a brew package called emojify. Itā€™s very satisfying. I donā€™t have a pipeline to get them directly into vim though, that would be more of an emacs power move that feels unnecessary for my desires.