[GSoC] Rust: Compiling the alloc crate - Status Report 2

Enes Cevik via Gcc <[email protected]> Tue, 23 Jun 2026 19:45:05 +0300
Newsgroups gmane.comp.gcc.devel
Message-ID <[email protected]>
Hi!
This is the second report on compiling the alloc crate with GCCRS.

This week I set out to:
- Complete the 'owned_box' implementation.
- Implement the 'box_free' lang item, which is required to ensure a
   function exists when Box deallocates memory.
- Begin implementing intrinsics related to fat pointers, time
   permitting.

Over the week:
- Completed the 'owned_box' implementation. This included implementing
   the box expression and utilizing the 'exchange_malloc' feature.
- Added an intrinsic signature validator to the typechecker.
- Implemented the 'min_align_of' intrinsic.

Current status:
- First, I will refactor the fat pointer structure. The current vtable
   is an array embedded directly within the fat pointer struct; I will
   change this so that the vtable is a static struct, ensuring that fat
   pointers are always 2 words in size.
- Following this, the 'coerce_unsized' and 'unsize' lang items will
   be implemented.
- Then, I plan to implement the 'size_of_val' and 'min_align_of_val'
   intrinsics.

Best regards,
Enes