On Apr 21, 2007, at 12:41 PM, chromatic wrote:
On Saturday 21 April 2007 04:01, Joshua Isom wrote:
I'm getting failures in t/pmc/class.t, t/pmc/exporter.t,
t/pmc/pccmethod_test.t, t/pmc/role.t, and t/pmc/smop_attribute.t and
all seem to be related to PCCMETHOD's. The failures occur in
inter_call.c, fetch_arg_op(). The macro's of UVal_* are where it
occurs, but I can't yet figure out where the bad data comes into it.
Can you post the verbose output of the tests? If they're all similar
or
identical, just one is fine.
-- c
Each failure occurs with the PCCMETHODs. Looking a little more, the
optional parameters seem to be the ones causing trouble. Somehow,
interp->current_args points to bad data. It looks to always be
something like 0x7fffffxxxxxx, and it just crashes later on. I'll look
more into it later unless someone figures the fix.
% prove -v t/pmc/class.t t/pmc/exporter.t t/pmc/pccmethod_test.t
t/pmc/role.t t/pmc/smop_attribute.t
t/pmc/class.............1..15
ok 1 - new
ok 2 - Class PMC has "I am a class" flag set
not ok 3 - name
# Failed test (t/pmc/class.t at line 62)
# got: 'Bus error (core dumped)
# '
# expected: 'ok 1 - name() with no args returns class name, which
is empty at first
# ok 2 - name() with args sets class name
# ok 3 - name() with too many args fails
# ok 4 - name() with args sets namespace too
# '
# './parrot "/usr/home/jisom/parrot/t/pmc/class_3.pir"' failed with
exit code 138
ok 4 - new
ok 5 - attributes
ok 6 - add_attribute
not ok 7 - set_attr/get_attr VTABLE methods
# Failed test (t/pmc/class.t at line 219)
# got: 'Bus error (core dumped)
# '
# expected: 'ok 1 - created a class with two attributes
# ok 2 - instantiated the class
# ok 3 - set an attribute
# 42
# ok 4 - got an attribute
# '
# './parrot "/usr/home/jisom/parrot/t/pmc/class_7.pir"' failed with
exit code 138
ok 8 - parents
ok 9 - roles
not ok 10 - inspect PCCMETHOD
# Failed test (t/pmc/class.t at line 290)
# got: 'Bus error (core dumped)
# '
# expected: 'ok 1 - inspect with no args called
# ok 2 - returned hash had correct number of elements
# foo
# ok 3 - inspect('name')
# ok 4 - inspect('attributes')
# '
# './parrot "/usr/home/jisom/parrot/t/pmc/class_10.pir"' failed with
exit code 138
not ok 11 - clone
# Failed test (t/pmc/class.t at line 324)
# got: 'ok 1 - created class Monkey and instantiated it
# ok 2 - cloned class Monkey
# Bus error (core dumped)
# '
# expected: 'ok 1 - created class Monkey and instantiated it
# ok 2 - cloned class Monkey
# ok 3 - name is empty
# ok 4 - namespace is null
# ok 5 - attribute survived cloning
# ok 6 - can modify cloned class
# '
# './parrot "/usr/home/jisom/parrot/t/pmc/class_11.pir"' failed with
exit code 138
not ok 12 - clone_pmc
# Failed test (t/pmc/class.t at line 367)
# got: 'ok 1 - created class Monkey and instantiated it
# ok 2 - cloned class Monkey with Hash argument
# Bus error (core dumped)
# '
# expected: 'ok 1 - created class Monkey and instantiated it
# ok 2 - cloned class Monkey with Hash argument
# ok 3 - name is new one set in the Hash
# ok 4 - namespace is Mandrill too
# ok 5 - attribute survived cloning
# ok 6 - can modify cloned class
# '
# './parrot "/usr/home/jisom/parrot/t/pmc/class_12.pir"' failed with
exit code 138
ok 13 - new with initialization hash
ok 14 - isa()
not ok 15 - does()
# Failed test (t/pmc/class.t at line 498)
# got: 'Doesn't Red
# Bus error (core dumped)
# '
# expected: 'Doesn't Red
# Does Red
# Does Green
# Does Blue
# Does Class
# '
# './parrot "/usr/home/jisom/parrot/t/pmc/class_15.pir"' failed with
exit code 138
# Looks like you failed 6 tests of 15.
dubious
Test returned status 6 (wstat 1536, 0x600)
DIED. FAILED tests 3, 7, 10-12, 15
Failed 6/15 tests, 60.00% okay
t/pmc/exporter..........1..10
ok 1 - new
not ok 2 - source
# Failed test (t/pmc/exporter.t at line 43)
# got: 'Bus error (core dumped)
# '
# expected: 'ok 1 - source() returns PMCNULL upon Exporter init
# ok 2 - source() with args sets source namespace
# ok 3 - source() with too many args fails
# ok 4 - source() with non-namespace arg throws exception
# '
# './parrot "/usr/home/jisom/parrot/t/pmc/exporter_2.pir"' failed
with exit code 138
not ok 3 - destination
# Failed test (t/pmc/exporter.t at line 95)
# got: 'Bus error (core dumped)
# '
# expected: 'ok 1 - destination() with no args returns destination
namespace
# ok 2 - ...which is current namespace at first
# ok 3 - destination() with args sets destination namespace
# ok 4 - destination() with too many args fails
# ok 5 - destination() with non-namespace arg throws exception
# '
# './parrot "/usr/home/jisom/parrot/t/pmc/exporter_3.pir"' failed
with exit code 138
ok 4 - globals
ok 5 - add_global
ok 6 - import - no args
ok 7 - import - same source and destination namespaces
ok 8 - import - globals as string
ok 9 - import - globals as array
ok 10 - import - globals with destination
# Looks like you failed 2 tests of 10.
dubious
Test returned status 2 (wstat 512, 0x200)
DIED. FAILED tests 2-3
Failed 2/10 tests, 80.00% okay
t/pmc/pccmethod_test....1..2
ok 1 - named args
not ok 2 - optional args and multiple returns
# Failed test (t/pmc/pccmethod_test.t at line 36)
# got: 'test_method0
# 1
# test_method1
# 1,2,3,4,5,6
# test_method2
# 0, 0, ResizablePMCArray [ ]
# test_method2
# 1, 1, ResizablePMCArray [ ]
# test_method2
# 1, 1, ResizablePMCArray [ 2 ]
# test_method2
# 1, 1, ResizablePMCArray [ 2, 3 ]
# test_method2
# 101, 1, ResizablePMCArray [ ]
# Segmentation fault (core dumped)
# '
# expected: 'test_method0
# 1
# test_method1
# 1,2,3,4,5,6
# test_method2
# 0, 0, ResizablePMCArray [ ]
# test_method2
# 1, 1, ResizablePMCArray [ ]
# test_method2
# 1, 1, ResizablePMCArray [ 2 ]
# test_method2
# 1, 1, ResizablePMCArray [ 2, 3 ]
# test_method2
# 101, 1, ResizablePMCArray [ ]
# BACK - 1000 - KEVIN -
# '
# './parrot "/usr/home/jisom/parrot/t/pmc/pccmethod_test_2.pir"'
failed with exit code 139
# Looks like you failed 1 test of 2.
dubious
Test returned status 1 (wstat 256, 0x100)
DIED. FAILED test 2
Failed 1/2 tests, 50.00% okay
t/pmc/role..............1..5
ok 1 - Role type exists
ok 2 - isa Role
ok 3 - Created a Role initialized with a Hash
dubious
Test returned status 0 (wstat 138, 0x8a)
DIED. FAILED tests 4-5
Failed 2/5 tests, 60.00% okay
t/pmc/smop_attribute....1..9
ok 1 - The object isa SMOP_Attribute
dubious
Test returned status 0 (wstat 138, 0x8a)
DIED. FAILED tests 2-9
Failed 8/9 tests, 11.11% okay
Failed Test Stat Wstat Total Fail List of Failed
------------------------------------------------------------------------
-------
t/pmc/class.t 6 1536 15 6 3 7 10-12 15
t/pmc/exporter.t 2 512 10 2 2-3
t/pmc/pccmethod_test.t 1 256 2 1 2
t/pmc/role.t 0 138 5 4 4-5
t/pmc/smop_attribute.t 0 138 9 16 2-9
Failed 5/5 test scripts. 19/41 subtests failed.
Files=5, Tests=41, 2 wallclock secs ( 1.04 cusr + 0.70 csys = 1.73
CPU)
Failed 5/5 test programs. 19/41 subtests failed.