Edited to note that Shay Gueron and Vlad Krasnov have already done this, for NSS's MASM.