krfkeith / slate-language

Automatically exported from code.google.com/p/slate-language
MIT License
1 stars 0 forks source link

"derive" crashes 32-bit VM #35

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
-- Enter this line based on the derivation example from the GettingStarted page:

addSlot: #z valued: 1 derive.

What is the expected output? What do you see instead?
-- A new slot ;)  But I get an infinite memory-chewing loop instead:

cslatevm$ ./slate
Nil
slate[1]> define: #x &parents: {Cloneable}.
("x traitsWindow")
slate[2]> addSlot: #y valued: x clone.     
("x traitsWindow")
slate[3]>  addSlot: #z valued: x derive.
Couldn't allocate 8388640 bytes... using oldspace
Couldn't allocate 16777248 bytes... using oldspace
Couldn't allocate 33554464 bytes... using oldspace
Couldn't allocate 67108896 bytes... using oldspace
Couldn't allocate 134217760 bytes... using oldspace
Couldn't allocate 268435488 bytes... using oldspace
slate: gc.cpp:247: Object* gc_allocate_old(object_heap*, word_t): Assertion 
`oh->memoryOldSize+bytes < oh->memoryOldLimit' failed.
Aborted (core dumped)

What version of the product are you using? On what operating system?

-- git master (git://repo.or.cz/cslatevm.git, 2010/09/12), Linux/x86 
2.6.31-22-generic
-- Using slate.little.32.2010-04-01.image (and 2010-03-15, and 2010-02-15)
-- Tried the optimized and debug builds (gcc 4.4.1)

Please provide any additional information below.

-- I tried re-bootstrapping, in case the image was borked, and ran into other 
errors (below).  Haven't tried on 64-bit.

cslatevm$ make bootstrap
Bootstrapping new images
./src/vm/vm -q -i slate.image --load src/mobius/init.slate --eval "Image 
bootstrap &bootstrapDirectory: '.' &littleEndian: True &wordSize: ." --eval 
"quit"
 Loading P'src/mobius/init.slate'
  Loading P'src/mobius/bootstrap.slate'
  Loading P'src/mobius/build.slate'
Adding primitives
Debugging: MethodNotFound traitsWindow
The following condition was signaled:
The method #evaluateIn: was not found for the following arguments:
{Nil. lobby}

Original issue reported on code.google.com by eswa...@austin.rr.com on 12 Sep 2010 at 2:36

GoogleCodeExporter commented 9 years ago
Wow, I didn't get notified about this bug for some reason. I think this is just 
a case of the documentation and release state being inadequately maintained. 
Stay tuned for a major update. Also, the "cslatevm" repo is now out of date.

The bug is definitely valid, though, even if #derive is not a recommended API 
any more. I'll find out why in the process of clarifying the recommended 
"getting started" content.

Original comment by BrianTRice on 18 Nov 2010 at 12:31