truffleruby icon indicating copy to clipboard operation
truffleruby copied to clipboard

Investigate failures in oj test suite

Open eregon opened this issue 3 years ago • 4 comments

See https://github.com/ohler55/oj/pull/804/files Some missing C API functions (like rb_ivar_foreach), some differences and some segfaults.

It might be useful to run this with managed Sulong regarding the segfaults to find the invalid memory accesses.

eregon avatar Aug 06 '22 11:08 eregon

rb_ivar_foreach seems pretty simple, though it has some special cases in MRI for classes and modules. Implementing that allows most of those skipped specs to pass, but we get two failures and 1 error for trying to call __allocate__ on something which we don't support it on. I'll take a bit more of a look and create some issues for the problems.

aardvark179 avatar Aug 08 '22 11:08 aardvark179

PRs submitted to OJ so far

  • https://github.com/ohler55/oj/pull/810
  • https://github.com/ohler55/oj/pull/811
  • https://github.com/ohler55/oj/pull/812
  • https://github.com/ohler55/oj/pull/813

aardvark179 avatar Aug 23 '22 12:08 aardvark179

Most issues with the oj gem should be fixed now with https://github.com/oracle/truffleruby/commit/01607d7343517e3f04ea599416beca78e9c6d73b. We need to make a PR to oj to remove the now-unecessary skips.

eregon avatar Sep 03 '22 10:09 eregon

I have a branch removing most skips: https://github.com/ohler55/oj/compare/develop...eregon:oj:remove_most_truffleruby_skips I'll fix rb_struct_s_members/rb_struct_members first though.

eregon avatar Sep 05 '22 14:09 eregon

Most skips are removed with https://github.com/ohler55/oj/pull/817.

eregon avatar Oct 05 '22 15:10 eregon