@@ -162,7 +162,7 @@ JL_DLLEXPORT void jl_gc_set_max_memory(uint64_t max_mem) {
162162 // MMTk currently does not allow setting the heap size at runtime
163163}
164164
165- inline void maybe_collect (jl_ptls_t ptls )
165+ STATIC_INLINE void maybe_collect (jl_ptls_t ptls )
166166{
167167 // Just do a safe point for general maybe_collect
168168 jl_gc_safepoint_ (ptls );
@@ -792,12 +792,12 @@ int jl_gc_classify_pools(size_t sz, int *osize)
792792
793793#define MMTK_MIN_ALIGNMENT 4
794794// MMTk assumes allocation size is aligned to min alignment.
795- inline size_t mmtk_align_alloc_sz (size_t sz ) JL_NOTSAFEPOINT
795+ STATIC_INLINE size_t mmtk_align_alloc_sz (size_t sz ) JL_NOTSAFEPOINT
796796{
797797 return (sz + MMTK_MIN_ALIGNMENT - 1 ) & ~(MMTK_MIN_ALIGNMENT - 1 );
798798}
799799
800- inline void * bump_alloc_fast (MMTkMutatorContext * mutator , uintptr_t * cursor , uintptr_t limit , size_t size , size_t align , size_t offset , int allocator ) {
800+ STATIC_INLINE void * bump_alloc_fast (MMTkMutatorContext * mutator , uintptr_t * cursor , uintptr_t limit , size_t size , size_t align , size_t offset , int allocator ) {
801801 intptr_t delta = (- offset - * cursor ) & (align - 1 );
802802 uintptr_t result = * cursor + (uintptr_t )delta ;
803803
@@ -809,7 +809,7 @@ inline void* bump_alloc_fast(MMTkMutatorContext* mutator, uintptr_t* cursor, uin
809809 }
810810}
811811
812- inline void * mmtk_immix_alloc_fast (MMTkMutatorContext * mutator , size_t size , size_t align , size_t offset ) {
812+ STATIC_INLINE void * mmtk_immix_alloc_fast (MMTkMutatorContext * mutator , size_t size , size_t align , size_t offset ) {
813813 ImmixAllocator * allocator = & mutator -> allocators .immix [MMTK_DEFAULT_IMMIX_ALLOCATOR ];
814814 return bump_alloc_fast (mutator , (uintptr_t * )& allocator -> cursor , (intptr_t )allocator -> limit , size , align , offset , 0 );
815815}
@@ -818,17 +818,17 @@ inline void mmtk_immix_post_alloc_slow(MMTkMutatorContext* mutator, void* obj, s
818818 mmtk_post_alloc (mutator , obj , size , 0 );
819819}
820820
821- inline void mmtk_immix_post_alloc_fast (MMTkMutatorContext * mutator , void * obj , size_t size ) {
821+ STATIC_INLINE void mmtk_immix_post_alloc_fast (MMTkMutatorContext * mutator , void * obj , size_t size ) {
822822 // FIXME: for now, we do nothing
823823 // but when supporting moving, this is where we set the valid object (VO) bit
824824}
825825
826- inline void * mmtk_immortal_alloc_fast (MMTkMutatorContext * mutator , size_t size , size_t align , size_t offset ) {
826+ STATIC_INLINE void * mmtk_immortal_alloc_fast (MMTkMutatorContext * mutator , size_t size , size_t align , size_t offset ) {
827827 BumpAllocator * allocator = & mutator -> allocators .bump_pointer [MMTK_IMMORTAL_BUMP_ALLOCATOR ];
828828 return bump_alloc_fast (mutator , (uintptr_t * )& allocator -> cursor , (uintptr_t )allocator -> limit , size , align , offset , 1 );
829829}
830830
831- inline void mmtk_immortal_post_alloc_fast (MMTkMutatorContext * mutator , void * obj , size_t size ) {
831+ STATIC_INLINE void mmtk_immortal_post_alloc_fast (MMTkMutatorContext * mutator , void * obj , size_t size ) {
832832 // FIXME: Similarly, for now, we do nothing
833833 // but when supporting moving, this is where we set the valid object (VO) bit
834834 // and log (old gen) bit
0 commit comments