[parrot/parrot] 58d34f: [test] minor improvements in stress/gc.t and src/e...

GitHub noreply at github.com
Thu Dec 4 15:14:45 UTC 2014


  Branch: refs/heads/smoke-me/rpa-offset-gh1152
  Home:   https://github.com/parrot/parrot
  Commit: 58d34f2889809e8329e3f08f6a29b67ad2ef0eb2
      https://github.com/parrot/parrot/commit/58d34f2889809e8329e3f08f6a29b67ad2ef0eb2
  Author: Reini Urban <rurban at cpanel.net>
  Date:   2014-12-04 (Thu, 04 Dec 2014)

  Changed paths:
    M t/src/extend.t
    M t/stress/gc.t

  Log Message:
  -----------
  [test] minor improvements in stress/gc.t and src/extend.t 19


  Commit: 2835be36ecf7f2a9e27fe08b4e197eb626eb2f6e
      https://github.com/parrot/parrot/commit/2835be36ecf7f2a9e27fe08b4e197eb626eb2f6e
  Author: Reini Urban <rurban at cpanel.net>
  Date:   2014-12-04 (Thu, 04 Dec 2014)

  Changed paths:
    M examples/sdl/tetris/app.pir

  Log Message:
  -----------
  [examples] fix wrong load_bytecode paths


  Commit: 570e6c1c42ccf7e20c40b008c6a1c24abf6cf5e4
      https://github.com/parrot/parrot/commit/570e6c1c42ccf7e20c40b008c6a1c24abf6cf5e4
  Author: Reini Urban <rurban at cpanel.net>
  Date:   2014-12-04 (Thu, 04 Dec 2014)

  Changed paths:
    M config/auto/pmc.pm
    M lib/Parrot/Pmc2c/PMC.pm

  Log Message:
  -----------
  [build] change add_to_generated for .dump files

move from pmc2c.pl to Makefile.
1. generated default.dump also, which was missing most of the time.
2. 3rd party langs may not need MANIFEST.generate files. let them handle it.


  Commit: e04e1e31ab41e51d76a10c04b11cc193989e3050
      https://github.com/parrot/parrot/commit/e04e1e31ab41e51d76a10c04b11cc193989e3050
  Author: Reini Urban <rurban at cpanel.net>
  Date:   2014-12-04 (Thu, 04 Dec 2014)

  Changed paths:
    M src/pmc/class.pmc
    M src/pmc/resizablepmcarray.pmc
    M src/runcore/trace.c

  Log Message:
  -----------
  [pmc] start with resizablepmcarray unshift optimizations

using a max offset 8, as in nqp/qrpa. See GH #1152
Here offset is still const 0.


  Commit: 58bbda3eb65805668b4d6e44b798fdb1d374019e
      https://github.com/parrot/parrot/commit/58bbda3eb65805668b4d6e44b798fdb1d374019e
  Author: Reini Urban <rurban at cpanel.net>
  Date:   2014-12-04 (Thu, 04 Dec 2014)

  Changed paths:
    M src/events.c
    M src/pmc/resizablepmcarray.pmc

  Log Message:
  -----------
  [pmc] rpa trace: do_shift(INTERP, ...)

need interp for tracing, slow or fast


  Commit: e08d1625ba38e58fc9fea45f5e09ee06bb839efa
      https://github.com/parrot/parrot/commit/e08d1625ba38e58fc9fea45f5e09ee06bb839efa
  Author: Reini Urban <rurban at cpanel.net>
  Date:   2014-12-04 (Thu, 04 Dec 2014)

  Changed paths:
    M src/pmc/fixedpmcarray.pmc
    M src/pmc/resizablepmcarray.pmc

  Log Message:
  -----------
  [pmc] rpa enabled shift optimizations w/o splice

resizablepmcarray shift,unshift,resize,push,pop look now good.
just splice is missing. GH #1152


  Commit: e53a2ef78d515ad3bc7b496780c36fed718e608d
      https://github.com/parrot/parrot/commit/e53a2ef78d515ad3bc7b496780c36fed718e608d
  Author: Reini Urban <rurban at cpanel.net>
  Date:   2014-12-04 (Thu, 04 Dec 2014)

  Changed paths:
    M src/pmc/resizablepmcarray.pmc

  Log Message:
  -----------
  [pmc] rpa: trying to fix splice WIP

Not offset optimized yet. And something still fails.
GH #1152


  Commit: 588e44714a4a992474dab8df98638db1b7969614
      https://github.com/parrot/parrot/commit/588e44714a4a992474dab8df98638db1b7969614
  Author: Reini Urban <rurban at cpanel.net>
  Date:   2014-12-04 (Thu, 04 Dec 2014)

  Changed paths:
    M src/pmc/resizablepmcarray.pmc

  Log Message:
  -----------
  [pmc] rpa: WIP some more fixes, but still failing


  Commit: 670c8a0289e1b047de78ec10d90c7a8c918637c1
      https://github.com/parrot/parrot/commit/670c8a0289e1b047de78ec10d90c7a8c918637c1
  Author: Reini Urban <rurban at cpanel.net>
  Date:   2014-12-04 (Thu, 04 Dec 2014)

  Changed paths:
    M src/pmc/resizablepmcarray.pmc

  Log Message:
  -----------
  [pmc] rpa: remove old code without USE_OFFSET

Still one invalid access of freed data in push_pmc, and
invalid read in shift_pmc.
valgrind ./parrot_old -o runtime/parrot/library/HLL.pbc ext/nqp-rx/src/stage0/HLL-s0.pir


  Commit: 386af50e08aa5e3f8ea8db9ff3fb9e84b3e8ef28
      https://github.com/parrot/parrot/commit/386af50e08aa5e3f8ea8db9ff3fb9e84b3e8ef28
  Author: Reini Urban <rurban at cpanel.net>
  Date:   2014-12-04 (Thu, 04 Dec 2014)

  Changed paths:
    M src/pmc/resizablepmcarray.pmc

  Log Message:
  -----------
  [pmc] rpa: fix 2 cases: shift+push offset overflow

also:
* fix non-debugging TRACE_RPAd macro
* add some UNLIKELY hints


  Commit: 17d7d92e97bcd3d0eda95dba15dbdb855f0f27c7
      https://github.com/parrot/parrot/commit/17d7d92e97bcd3d0eda95dba15dbdb855f0f27c7
  Author: Reini Urban <rurban at cpanel.net>
  Date:   2014-12-04 (Thu, 04 Dec 2014)

  Changed paths:
    M src/pmc/resizablepmcarray.pmc

  Log Message:
  -----------
  [pmc] rpa: fix defined, no throw. add get/set trace with -t1


  Commit: 2d1d2f2b2558e48b44fd32b22792820d9f94d2aa
      https://github.com/parrot/parrot/commit/2d1d2f2b2558e48b44fd32b22792820d9f94d2aa
  Author: Reini Urban <rurban at cpanel.net>
  Date:   2014-12-04 (Thu, 04 Dec 2014)

  Changed paths:
    M src/pmc/fixedpmcarray.pmc
    M src/pmc/resizablepmcarray.pmc

  Log Message:
  -----------
  [pmc] rpa: specialize sort+reverse, need offset

also add offset to append
add more notes to fixedpmcarray vtable docs


  Commit: 51670590eb81c7b17e8d5f3e2dd3a734940d566c
      https://github.com/parrot/parrot/commit/51670590eb81c7b17e8d5f3e2dd3a734940d566c
  Author: Reini Urban <rurban at cpanel.net>
  Date:   2014-12-04 (Thu, 04 Dec 2014)

  Changed paths:
    M src/pmc/resizablepmcarray.pmc

  Log Message:
  -----------
  [pmc] rpa: optimize splice shrink fast on offset

if there is enough room at the left to fill in the elements
from from, adjust offset and jump to the fill routine

this optimization is not present in qrpa, and executed e.g.
in data_json.


  Commit: 83aa896581447638ae71e510b34ca41f3f474d17
      https://github.com/parrot/parrot/commit/83aa896581447638ae71e510b34ca41f3f474d17
  Author: Reini Urban <rurban at cpanel.net>
  Date:   2014-12-04 (Thu, 04 Dec 2014)

  Changed paths:
    M src/pmc/resizablepmcarray.pmc

  Log Message:
  -----------
  [pmc] rpa: optimize splice resize a bit

add TRACE_SPLC


  Commit: 9fd5d2d1f98abdbcf3f68015cc978735ef5b8371
      https://github.com/parrot/parrot/commit/9fd5d2d1f98abdbcf3f68015cc978735ef5b8371
  Author: Reini Urban <rurban at cpanel.net>
  Date:   2014-12-04 (Thu, 04 Dec 2014)

  Changed paths:
    M src/pmc/resizablepmcarray.pmc

  Log Message:
  -----------
  [pmc] rpa: fix resize move with offset

before 1,32,8 => only 32. after: 33


  Commit: f5aa7fc562570ac8f953be56a9d9613dfa9c8267
      https://github.com/parrot/parrot/commit/f5aa7fc562570ac8f953be56a9d9613dfa9c8267
  Author: Reini Urban <rurban at cpanel.net>
  Date:   2014-12-04 (Thu, 04 Dec 2014)

  Changed paths:
    M config/gen/makefiles/root.in
    M src/events.c
    M src/pmc/resizablepmcarray.pmc
    M t/pmc/resizablepmcarray.t

  Log Message:
  -----------
  [pmc] rpa: fix splice shrink fast, add tests

test rpa coverage and add all missing tests
shrink fast has a wrong offset, test splice_shrink_fast()
add tests for resize off empty and resize off move, the 2 fast
  variants with existing offset.
remove shift slow case, this is invalid, add assertion. this is caught
by size == 0 and we cannot have an offset bigger then the threshold.

remove unnedeed pmc/pmc_arrayiterator.h from src/events.c


  Commit: 399356d8c6b09fd8bdac900a60c20f3852d5bf37
      https://github.com/parrot/parrot/commit/399356d8c6b09fd8bdac900a60c20f3852d5bf37
  Author: Reini Urban <rurban at cpanel.net>
  Date:   2014-12-04 (Thu, 04 Dec 2014)

  Changed paths:
    M src/pmc/fixedpmcarray.pmc
    M src/pmc/resizablepmcarray.pmc

  Log Message:
  -----------
  [pmc] rpa: fix visit

we need an offset for visit, we cannot use the fixedpmcarray
method.


  Commit: cec80e0a640dd0fc25dd0cea3490d794f228adaf
      https://github.com/parrot/parrot/commit/cec80e0a640dd0fc25dd0cea3490d794f228adaf
  Author: Reini Urban <rurban at cpanel.net>
  Date:   2014-12-04 (Thu, 04 Dec 2014)

  Changed paths:
    M src/pmc/resizablepmcarray.pmc
    M t/pmc/resizablepmcarray.t

  Log Message:
  -----------
  [pmc] rpa: fix resize with offset optimization

we moved the wrong items, and had wrong slack overwrites.
Add testcases.


  Commit: 0d998322573947627ce61b0573c4b390be6eb4ef
      https://github.com/parrot/parrot/commit/0d998322573947627ce61b0573c4b390be6eb4ef
  Author: Reini Urban <rurban at cpanel.net>
  Date:   2014-12-04 (Thu, 04 Dec 2014)

  Changed paths:
    M src/pmc/fixedpmcarray.pmc
    M src/pmc/imageiofreeze.pmc
    M src/pmc/resizablepmcarray.pmc
    M t/pmc/freeze.t

  Log Message:
  -----------
  [pmc] rpa,fpa,imageiofreeze: various minor refactors

* Access attr struct more directly.
* Fix one syntax problem with UNLIKELY with non-std compilers.
* Optimize *1.5 by using integer math.
* Change rpa overallocation to use 1.5, not 2. This is better to handle
  free blocks.
* Always fill slack space, as we extend rpa via set. In a better version we
  should fill the slack space only when needed: only on set.
* Change push_{non-pmc} to use push_pmc and not set_keyed_int.
  push is offset optimized, set not.

Still WIP. object was probably modified after being freed


  Commit: 2ef874bccdc00e2ab01a92d12ff97cf4fc55bc04
      https://github.com/parrot/parrot/commit/2ef874bccdc00e2ab01a92d12ff97cf4fc55bc04
  Author: Reini Urban <rurban at cpanel.net>
  Date:   2014-12-04 (Thu, 04 Dec 2014)

  Changed paths:
    M frontend/parrot/main.c
    M include/parrot/interpreter.h
    M src/pmc/resizablepmcarray.pmc
    M t/pmc/freeze.t

  Log Message:
  -----------
  [pmc] rpa: optimize slack filling with PMCNULL

Only fill the rest with PMCNULL when necessary, i.e. when
we set an index > size, the intermediate indices between size and index-1.
This saves a lot of slack filling code cycles.

Error on delete oob.


  Commit: 4a147d3a2d98f4824ecbfe78eff15254743193e2
      https://github.com/parrot/parrot/commit/4a147d3a2d98f4824ecbfe78eff15254743193e2
  Author: Reini Urban <rurban at cpanel.net>
  Date:   2014-12-04 (Thu, 04 Dec 2014)

  Changed paths:
    M src/pmc/resizablepmcarray.pmc

  Log Message:
  -----------
  [pmc] rpa: optimize delete_keyed_int

on index=0 just bump the offset as with shift,
else memmove en-block, not item by item in a loop.

This passes now most rpa related tests, just reverse has a conflict
with fpa. with reverse renamed to nreverse make test and benchmarking
is possible.


  Commit: 8b16d352090bc5a1eb069bd5cf29666c078e0a76
      https://github.com/parrot/parrot/commit/8b16d352090bc5a1eb069bd5cf29666c078e0a76
  Author: Reini Urban <rurban at cpanel.net>
  Date:   2014-12-04 (Thu, 04 Dec 2014)

  Changed paths:
    M ext/nqp-rx/src/stage0/nqp-setting.nqp
    M frontend/parrot/main.c
    M include/parrot/interpreter.h
    M src/hll.c

  Log Message:
  -----------
  [ext] fix the remaining rpa reverse problem

nqp ResizablePMCArray provided its own reverse method, which is now
not needed anymore. We use the better pir method instead.

Also found a syntax problem in parrot_old

Remaining todos:
t/op/lexicals.t                           (Wstat: 256 Tests: 54 Failed: 1)
  Failed test:  27
t/compilers/pge/p5regex/p5rx.t            (Wstat: 0 Tests: 960 Failed: 7)
  Failed tests:  172, 420-421, 442-443, 869-870
t/src/extend_vtable.t                     (Wstat: 512 Tests: 134 Failed: 2)
  Failed tests:  34, 37


  Commit: 5f23d873595572d28d74a577daa2af15af91168c
      https://github.com/parrot/parrot/commit/5f23d873595572d28d74a577daa2af15af91168c
  Author: Reini Urban <rurban at cpanel.net>
  Date:   2014-12-04 (Thu, 04 Dec 2014)

  Changed paths:
    M frontend/parrot/main.c
    M frontend/parrot2/main.c
    M include/parrot/interpreter.h
    M src/pmc/resizablepmcarray.pmc

  Log Message:
  -----------
  [core] apify -t20 as PARROT_TRACE_ARRAY_STATE_FLAG

Only available without --optimize, i.e. #ifndef NDEBUG


  Commit: 9bca8bb9d2cfb1ceef3033b7121f05bc8f5c3d61
      https://github.com/parrot/parrot/commit/9bca8bb9d2cfb1ceef3033b7121f05bc8f5c3d61
  Author: Reini Urban <rurban at cpanel.net>
  Date:   2014-12-04 (Thu, 04 Dec 2014)

  Changed paths:
    M src/pmc/resizablepmcarray.pmc

  Log Message:
  -----------
  [pmc] rpa: fix a resize edgecase with size=0

avoid negative offsets.
repro:
  valgrind ./parrot_old -t20 parrot-nqp.pbc --target=pir compilers/data_json/JSON.nqp


  Commit: d642a3ce31be2564230c712371ac13d4a101a2a6
      https://github.com/parrot/parrot/commit/d642a3ce31be2564230c712371ac13d4a101a2a6
  Author: Reini Urban <rurban at cpanel.net>
  Date:   2014-12-04 (Thu, 04 Dec 2014)

  Changed paths:
    M src/pmc/resizablepmcarray.pmc

  Log Message:
  -----------
  [pmc] rpa: fix invalid read in delete_keyed_int, off by one

with (1,9,10) and key=1 we read one too far.
repro:
  valgrind ./parrot_old -t20 t/compilers/pge/p5regex/p5rx.t


  Commit: e439b764821f320796cbf1cee30cf0dc8d344b0f
      https://github.com/parrot/parrot/commit/e439b764821f320796cbf1cee30cf0dc8d344b0f
  Author: Reini Urban <rurban at cpanel.net>
  Date:   2014-12-04 (Thu, 04 Dec 2014)

  Changed paths:
    M src/pmc/resizablepmcarray.pmc

  Log Message:
  -----------
  [pmc] rpa: shift optim, use data struct directly

do not use seperate SELF and temp values for the attrs.
2.40% faster on my mac, %ebp addressing for data.


  Commit: eb71e05f6eaf9f95eab4bdf178127f5772b10774
      https://github.com/parrot/parrot/commit/eb71e05f6eaf9f95eab4bdf178127f5772b10774
  Author: Reini Urban <rurban at cpanel.net>
  Date:   2014-12-04 (Thu, 04 Dec 2014)

  Changed paths:
    M src/pmc/resizablepmcarray.pmc

  Log Message:
  -----------
  [pmc] rpa: internal rename trace macros

add TRACE_RPAdata


  Commit: 67d528010301d78eb223d3b81d6b0368a0ff12b0
      https://github.com/parrot/parrot/commit/67d528010301d78eb223d3b81d6b0368a0ff12b0
  Author: Reini Urban <rurban at cpanel.net>
  Date:   2014-12-04 (Thu, 04 Dec 2014)

  Changed paths:
    M src/pmc/resizablepmcarray.pmc
    M t/pmc/resizablepmcarray.t

  Log Message:
  -----------
  [pmc] rpa refactor delete_keyed_int, add tests

also prepare do_unshift optimization, add slack offset if slow


  Commit: 152430183197bc64e4ad9b0cb14299d8d2622561
      https://github.com/parrot/parrot/commit/152430183197bc64e4ad9b0cb14299d8d2622561
  Author: Reini Urban <rurban at cpanel.net>
  Date:   2014-12-04 (Thu, 04 Dec 2014)

  Changed paths:
    M lib/Parrot/Test.pm
    M t/src/extend_vtable.t

  Log Message:
  -----------
  [test] fix extend_vtable.t for changed rpa delete API

delete throws now out of bounds.
Also enable TEST_VERBOSE=2 for c_output tests


  Commit: 0004a834bf9459f7364d2c99fba3425f3764de8f
      https://github.com/parrot/parrot/commit/0004a834bf9459f7364d2c99fba3425f3764de8f
  Author: Reini Urban <rurban at cpanel.net>
  Date:   2014-12-04 (Thu, 04 Dec 2014)

  Changed paths:
    M src/pmc/resizablepmcarray.pmc

  Log Message:
  -----------
  [pmc] rpa: just aesthetics


  Commit: d045ccd7d79b8e5c91df88e541d669d0b27126e5
      https://github.com/parrot/parrot/commit/d045ccd7d79b8e5c91df88e541d669d0b27126e5
  Author: Reini Urban <rurban at cpanel.net>
  Date:   2014-12-04 (Thu, 04 Dec 2014)

  Changed paths:
    M src/pmc/resizablepmcarray.pmc

  Log Message:
  -----------
  [pmc] rpa.delete warn on illegal delete[0] of empty array

it skipped the memmove, so did no harm. But PGE still uses that, so keep the warning
for one deprecation cycle. Closes GH #1153


  Commit: e4abc302a3ce51e4655530b00db650fd6ccf150b
      https://github.com/parrot/parrot/commit/e4abc302a3ce51e4655530b00db650fd6ccf150b
  Author: Reini Urban <rurban at cpanel.net>
  Date:   2014-12-04 (Thu, 04 Dec 2014)

  Changed paths:
    M src/pmc/resizablepmcarray.pmc
    M t/src/extend_vtable.t

  Log Message:
  -----------
  [pmc] rpa.delete: skip memmove when not needed

also adjust changed out of bounds error message in one test


  Commit: 514ef74657e75faf9c70bf429d14f6ceaac06cfc
      https://github.com/parrot/parrot/commit/514ef74657e75faf9c70bf429d14f6ceaac06cfc
  Author: Reini Urban <rurban at cpanel.net>
  Date:   2014-12-04 (Thu, 04 Dec 2014)

  Changed paths:
    M compilers/pge/PGE/Exp.pir

  Log Message:
  -----------
  [PGE] fix delete oob in Match scope

Makes the matcher a bit slower. Fixes #1154


  Commit: e07a4008ae6aef16d2cb2bfa2b1e06dbe10ecaed
      https://github.com/parrot/parrot/commit/e07a4008ae6aef16d2cb2bfa2b1e06dbe10ecaed
  Author: Reini Urban <rurban at cpanel.net>
  Date:   2014-12-04 (Thu, 04 Dec 2014)

  Changed paths:
    M src/pmc/resizablepmcarray.pmc

  Log Message:
  -----------
  [pmc] rpa: fix one more resize edge-case

when we have a big enough offset, move the elements to the left,
but not too many. cap the diff.
Not almost all tests pass, just op/lexicals.t 27 fails


  Commit: d2ed2b1bc1fe51eaf001a2299a683e39e9b07367
      https://github.com/parrot/parrot/commit/d2ed2b1bc1fe51eaf001a2299a683e39e9b07367
  Author: Reini Urban <rurban at cpanel.net>
  Date:   2014-12-04 (Thu, 04 Dec 2014)

  Changed paths:
    M docs/pmc/array.pod
    M src/pmc/resizablepmcarray.pmc

  Log Message:
  -----------
  [docs] fix Array pmc docs

total overhaul.


Compare: https://github.com/parrot/parrot/compare/df61e1834d06...d2ed2b1bc1fe


More information about the parrot-commits mailing list