/[guile]/guile/guile-core/libguile/gc.h
ViewVC logotype

Diff of /guile/guile-core/libguile/gc.h

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.110 by mvo, Sun Jul 27 13:56:10 2003 UTC revision 1.111 by kryde, Tue Aug 12 21:08:34 2003 UTC
# Line 341  SCM_API char *scm_gc_strndup (const char Line 341  SCM_API char *scm_gc_strndup (const char
341  SCM_API void scm_remember_upto_here_1 (SCM obj);  SCM_API void scm_remember_upto_here_1 (SCM obj);
342  SCM_API void scm_remember_upto_here_2 (SCM obj1, SCM obj2);  SCM_API void scm_remember_upto_here_2 (SCM obj1, SCM obj2);
343  SCM_API void scm_remember_upto_here (SCM obj1, ...);  SCM_API void scm_remember_upto_here (SCM obj1, ...);
344    
345    /* In GCC we can force a reference to an SCM with a little do-nothing asm,
346       avoiding the code size and slowdown of an actual function call.
347       __volatile__ ensures nothing will be moved across the reference, and that
348       it won't be optimized away (or rather only if proved unreachable).
349       Unfortunately there doesn't seem to be any way to do the varargs
350       scm_remember_upto_here similarly.  */
351    
352    #ifdef __GNUC__
353    #define scm_remember_upto_here_1(x)             \
354      do {                                          \
355        __asm__ __volatile__ ("" : : "g" (x));      \
356      } while (0)
357    #define scm_remember_upto_here_2(x, y)          \
358      do {                                          \
359        scm_remember_upto_here_1 (x);               \
360        scm_remember_upto_here_1 (y);               \
361      } while (0)
362    #endif
363    
364  SCM_API SCM scm_return_first (SCM elt, ...);  SCM_API SCM scm_return_first (SCM elt, ...);
365  SCM_API int scm_return_first_int (int x, ...);  SCM_API int scm_return_first_int (int x, ...);
366  SCM_API SCM scm_permanent_object (SCM obj);  SCM_API SCM scm_permanent_object (SCM obj);

Legend:
Removed from v.1.110  
changed lines
  Added in v.1.111

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26