Skip to content

Instantly share code, notes, and snippets.

Segfault in progress

mark mark-i-m

Segfault in progress
View GitHub Profile
mark-i-m /
Last active September 25, 2020 05:46
Rust 2021 post

Rust 2021

I first got into Rust because a professor suggested writing an OS kernel in it as an interesting exercise. As a systems programmer, I came to really appreciate Rust because of it's safety guarantees, having spent a lot of time with C and C++. I still primarily think of Rust as a "systems language", even though that not what I primarily use it for.

Over time, I found myself primarily using Rust for:

  • hobby OS kernels
  • hobby distributed systems
  • CLI tools for use at work (this one kind of surprised me, but Rust is really good at it).
mark-i-m / diagram.tex
Created September 1, 2020 19:02
Diagram of rustc bootstrapping
View diagram.tex

Rust 2020 reflections

This is my third roadmap post... you can find the first two here:

This year, I am quite divided due to a bunch of competing desires:

  • I still want all of the things that I wanted last year. In particular, it would be great if OS developement could finally be done on stable rust. Things like inline asm are blocking this.
mark-i-m /
Last active December 24, 2018 20:13

Rust 2019: Technical Debt, Continued Productivity, and Stability

A response to the call for Rust 2019 posts

I hope this post doesn't come across as a laundry list of stuff to do. Mainly, I consider a lot of this to be technical debt, and I would like to see it paid down a bit. Most of them also happen to be pain points that I have come across in my own usage of Rust, so perhaps I'm biased! Feel free to let me know...

Some of these are also just ideas intended to get people thinking. At the end, I discuss the hypothetical Rust 2021.

(EDIT: feel free to discuss here:

mark-i-m / up.debug
Created November 5, 2018 02:56
vagrant up --debug
View up.debug
$ vagrant up --debug
INFO global: Vagrant version: 2.2.0
INFO global: Ruby version: 2.4.4
INFO global: RubyGems version:
INFO global: VAGRANT_INSTALLER_EMBEDDED_DIR="/opt/vagrant/embedded"
INFO global: VAGRANT_EXECUTABLE="/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/bin/vagrant"
INFO global: VAGRANT_LOG="debug"
WARN global: resolv replacement has not been enabled!

This is for the [Rust2018 initiative][rust2018]. I will try to keep this brief, since I'm sure you have read a bunch of these.

Technical Debt

I have to 100% agree with [@nrc's post][nrc]. I feel like Rust has a lot of great things in the pipeline, but it worries me that there are so many [open tracking issues][track] and open issues in general (over 3100 at time of writing).

mark-i-m /
Last active January 8, 2018 20:25
Trying out proposed inline asm syntax
pub unsafe extern "C" fn irq0() {
push %rax
movq $0, %rax
// No inputs
// No outputs
clobber("rax", "rsp")
mark-i-m / ycm_54c3rwsi.log
Created November 22, 2017 19:29
YCM server shut down
View ycm_54c3rwsi.log
2017-11-22 13:24:28,598 - ERROR - Unable to connect to server
Traceback (most recent call last):
File "/afs/", line 137, in _new_conn
(, self.port), self.timeout, **extra_kw)
File "/afs/", line 91, in create_connection
raise err
File "/afs/", line 81, in create_connection
ConnectionRefusedError: [Errno 111] Connection refused
mark-i-m /
Created July 18, 2017 01:47
Excerpt from x86_64 OS kernel interrupt/trap handling
pub unsafe extern "C" fn irq0() {
"push %rax
movq $$0, %rax "
: /* No outputs */
: /* No inputs */
: "rax", "rsp"
: "volatile"
extern crate bytes;
extern crate serde;
extern crate serde_json;
extern crate tokio_io;
extern crate tokio_proto;
use tokio_io::{AsyncRead, AsyncWrite};
use tokio_io::codec::{Decoder, Encoder, Framed};
use tokio_proto::pipeline::ServerProto;