(done-tick 0)
(next-secondary-tick secondary-gc-rate))
(let glib-thread-loop ()
- (let ((gc-tick (car (gc-timestamp))))
- (if (fix:< done-tick gc-tick)
- (with-glib-lock
- (lambda ()
- (%trace ";run-glib cleaning up\n")
- (run-glib-cleanups)
- (%trace ";run-glib clean up done\n")
- (set! done-tick gc-tick))))
- (if (fix:< next-secondary-tick gc-tick)
- (begin
- (%trace ";run-glib secondary-gc daemons\n")
- (run-glib-daemons)
- (%trace ";run-glib secondary-gc daemons done\n")
- (set! next-secondary-tick
- (fix:+ gc-tick secondary-gc-rate)))))
(with-glib-lock
(lambda ()
+ (let ((gc-tick (car (gc-timestamp))))
+ (if (fix:< done-tick gc-tick)
+ (begin
+ (%trace ";run-glib cleaning up\n")
+ (run-glib-cleanups)
+ (%trace ";run-glib clean up done\n")
+ (set! done-tick gc-tick)))
+ (if (fix:< next-secondary-tick gc-tick)
+ (begin
+ (%trace ";run-glib secondary-gc daemons\n")
+ (run-glib-daemons)
+ (%trace ";run-glib secondary-gc daemons done\n")
+ (set! next-secondary-tick
+ (fix:+ gc-tick secondary-gc-rate)))))
(with-thread-timer-stopped
(lambda ()
(let ((time (or (and (thread/next self) 0)