𝐈 𝐛𝐮𝐢𝐥𝐭 𝐚 𝐂 𝐝𝐞𝐛𝐮𝐠𝐠𝐞𝐫 𝐟𝐫𝐨𝐦 𝐬𝐜𝐫𝐚𝐭𝐜𝐡 𝐛𝐞𝐜𝐚𝐮𝐬𝐞 𝐈 𝐝𝐢𝐝𝐧'𝐭 𝐥𝐢𝐤𝐞 𝐕𝐒𝐂𝐨𝐝𝐞'𝐬. In CS 137, I wanted to really understand how the stack and heap work in C. Not just conceptually, but by watching memory change as my code runs. VSCode's debugger wasn't cutting it for me, so I built my own tool from scratch and also used this as an excuse to learn Rust. CRusTTY is a C interpreter written 100% in Rust with a terminal UI that lets you: - Step forward and backward through your code - Watch the stack and heap update in real time - Catch memory bugs like use-after-free, null pointer dereferences, and buffer overruns as they happen It supports a solid subset of C: structs, pointers, pointer arithmetic, malloc/free, recursion, and more. The whole thing runs in your native terminal with no setup required. Building this taught me more about C's memory model than any lecture could... Sorry Victoria! Turns out the best way to understand how something works is to implement it yourself. MIT licensed and open source! github.com/aicheye/crustty #C #Rust #SystemsProgramming #ComputerScience #OpenSource

just started using it, crazy tool!

proud of you my young fletchling. excited to see what the future has in store for you.

Woww, thats so impressive, I found that the best motivation to work and FINISH on a project is to build something that you will actually use and helps in what you want to achieve!

Like
Reply

Wow! This is exactly what I needed for my computer systems class right now. Seeing something like this in action, stepping through the stack and heap, makes everything so much clearer. Perfect timing! 🙌🏻

wooow. super impressive. making a debuger is one the hardest things

Like
Reply

Super cool! Would've helped me avoid a few arduous debugging sessions chasing memory leaks during my undergrad.

Like
Reply

Crazy impressive, SEs are cracked

Like
Reply

This is class - respect man truly !

Like
Reply
See more comments

To view or add a comment, sign in

Explore content categories