Author: Patrick Rein <patrick.r...@student.hpi.uni-potsdam.de> Branch: Changeset: r794:4e58aee0b37c Date: 2014-04-22 13:14 +0200 http://bitbucket.org/pypy/lang-smalltalk/changeset/4e58aee0b37c/
Log: Added a basic readme diff --git a/README.md b/README.md new file mode 100644 --- /dev/null +++ b/README.md @@ -0,0 +1,69 @@ +Spy +========= + +A Squeak VM written in RPython, called "SPy VM". + +Setup +---- +### Required Projects +You need three repositories: +* This one +* pypy/pypy +* pypy/rsdl + +### Required packages +You need the following packages on your OS. Install with your favorite package +manager: +* pypy (For faster translation of the SPY VM) +* libsdl-dev + +### Adjusting the PYTHONPATH +In order to allow the RPython toolchain to find the rsdl module you have to add +the rsdl folder to the PYTHONPATH. Note that you have to add the rsdl subfolder +of the rsdl repository to the PYTHONPATH. + +``` +export PYTHONPATH=${PYTHONPATH}:[path to rsdl repository]/rsdl +``` + +### Setting the SDL Driver +For testing the basic functionality of the VM it is currently best to disable +the UI. You can do so by setting the SDL_VIDEODRIVER environment variable to +dummy. +``` +export SDL_VIDEODRIVER=dummy +``` + +### Building +To build the VM enter the following: + +``` +[path to pypy repository]/rpython/bin/rpython [path to lang-smalltalk +repository]/targetimageloadingsmalltalk.py +``` + +To build the VM with enabled just-in-time compiler: +``` +[path to pypy repository]/rpython/bin/rpython -O jit [path to lang-smalltalk +repository]/targetimageloadingsmalltalk.py +``` + +### Starting an image +The build process will produce an executable e.g. called +targetimageloadingsmalltalk-c. Start it with the following: +``` +./targetimageloadingsmalltalk-c images/Squeak4.5-*.image +``` + +Setup for stm-enabled SPY +--- +There are two branches integrating the RPython STM into SPY: stm-c4, +storage-stm-c4. You have to change two things of the setup to build those +branches. + +1. Change your local pypy repository to the stm-c4 branch. +2. Build using the following command: +``` +[path to pypy repository]/rpython/bin/rpython --gc=stmgc [path to lang-smalltalk +repository]/targetimageloadingsmalltalk.py +``` diff --git a/targetimageloadingsmalltalk.py b/targetimageloadingsmalltalk.py --- a/targetimageloadingsmalltalk.py +++ b/targetimageloadingsmalltalk.py @@ -223,8 +223,9 @@ # driver.config.translation.gcrootfinder = "stm" from rpython.rlib import rgc if hasattr(rgc, "stm_is_enabled"): - driver.config.translation.stm = True - driver.config.translation.thread = True + pass + #driver.config.translation.stm = True + #driver.config.translation.thread = True return entry_point, None _______________________________________________ pypy-commit mailing list pypy-commit@python.org https://mail.python.org/mailman/listinfo/pypy-commit