Skip to main content

MIPS32 assembler.

Project description

MIPS Assembler
==============

This is an (extremely) basic assembler for MIPS32. The end goal is to support all instructions on the standard MIPS [reference sheet](http://inst.eecs.berkeley.edu/~cs61c/resources/MIPS_Green_Sheet.pdf "MIPS reference sheet") (a.k.a. the "green sheet").

### Usage

Simply clone the repository and run
```sh
python assembler.py [-o out_filepath] in_filepath
```

This will produce an output file with the encoded instructions. My plan is to work on a better distribution method, specifically, the ability to call the assembler directly from the command line under any path.

### Labels

Labels are now supported. Either "format" is fine.

```
sort: addi $s0, $s0, -20
```
or
```
sort:
addi $s0, $s0, -20
```
will result in equivalent instruction memory.

### Goals

* All of the instructions. (At least as much as possible.)
* Better distribution/invocation.

### Credit

* Using the [bitstring](https://code.google.com/p/python-bitstring/ "bitstring") library for decimal to binary conversion. (It was easier than writing my own 2's complement converter.)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for mipsy, version 0.1.1
Filename, size File type Python version Upload date Hashes
Filename, size mipsy-0.1.1.tar.gz (6.1 kB) File type Source Python version None Upload date Hashes View

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring DigiCert DigiCert EV certificate Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page