Opened 9 years ago

Last modified 9 years ago

#1221 closed defect

Large / many constants cause segfaults — at Version 2

Reported by: sjamaan Owned by:
Priority: critical Milestone: 4.11.0
Component: unknown Version: 4.9.x
Keywords: Cc:
Estimated difficulty:

Description (last modified by sjamaan)

When compiling a Scheme program containing "many" constants that are reasonably large, the resulting binary will segfault.

(use-for-syntax srfi-1)

(define-syntax generate-literals
  (ir-macro-transformer
    (lambda (i r c)
     `(begin 
        ,@(list-tabulate
            1000
            (lambda (x) 
              `(define ,(gensym) (quote ,(make-vector 1000)))))))))

(generate-literals)

This happens with vectors as well as lists (but not strings, because those are allocated statically with malloc())

Change History (2)

comment:1 Changed 9 years ago by sjamaan

OK, looks like this is a size calculation problem in C_rereclaim2 (see chicken-hackers thread).

Last edited 9 years ago by sjamaan (previous) (diff)

comment:2 Changed 9 years ago by sjamaan

Description: modified (diff)
Note: See TracTickets for help on using tickets.