Author: Anton Gulenko <anton.gule...@googlemail.com> Branch: storage-display-refactoring Changeset: r938:39973aaf497d Date: 2014-07-22 21:54 +0200 http://bitbucket.org/pypy/lang-smalltalk/changeset/39973aaf497d/
Log: Removed --invert flag. diff --git a/spyvm/model_display.py b/spyvm/model_display.py --- a/spyvm/model_display.py +++ b/spyvm/model_display.py @@ -24,12 +24,6 @@ return w_display_bitmap -invert_byte_order = [False] - -def invert(): - inv = invert_byte_order[0] - return jit.promote(inv) - class W_DisplayBitmap(model.W_AbstractObjectWithClassReference): _attrs_ = ['pixelbuffer_words', '_real_depth_buffer', '_realsize', 'display', '_depth'] _immutable_fields_ = ['pixelbuffer_words?', '_real_depth_buffer', '_realsize', 'display', '_depth'] @@ -148,16 +142,13 @@ repr_classname = "W_8BitDisplayBitmap" def set_pixelbuffer_word(self, n, word): - if invert(): - # Invert the byte-order. - self.pixelbuffer_UINT()[n] = r_uint( - (word >> 24) | - ((word >> 8) & 0x0000ff00) | - ((word << 8) & 0x00ff0000) | - (word << 24) - ) - else: - self.pixelbuffer_UINT()[n] = r_uint(word) + # Invert the byte-order. + self.pixelbuffer_UINT()[n] = r_uint( + (word >> 24) | + ((word >> 8) & 0x0000ff00) | + ((word << 8) & 0x00ff0000) | + (word << 24) + ) BITS = r_uint(32) class W_MappingDisplayBitmap(W_DisplayBitmap): diff --git a/targetimageloadingsmalltalk.py b/targetimageloadingsmalltalk.py --- a/targetimageloadingsmalltalk.py +++ b/targetimageloadingsmalltalk.py @@ -122,9 +122,6 @@ headless = False elif arg in ["--hacks"]: space.run_spy_hacks.activate() - elif arg in ["--invert"]: - from spyvm import model_display - model_display.invert_byte_order[0] = True elif arg in ["-S"]: space.no_specialized_storage.activate() elif arg in ["-u"]: _______________________________________________ pypy-commit mailing list pypy-commit@python.org https://mail.python.org/mailman/listinfo/pypy-commit