wavefnd / wavefnd/Wave

Establish a 32-bit target baseline with i686 GNU/Linux

Open
#414 0 comments 0 reactions 0 assignees View on GitHub
cross-platform enhancement help wanted needs testing os support
Dominant language
Rust
Stars
53
Forks
16
Avg merge
4h 22m
Merged PRs (30d)
46

Description

## Goal

Wave currently registers only 64-bit architectures. Add `i686-unknown-linux-gnu` as the first 32-bit target so pointer-width assumptions are found and made explicit.

## Scope

- Add an i686 architecture/target spec and x86 LLVM initialization path.
- Make `isz`, `usz`, pointer arithmetic, array indexing, layouts, and constant casts honor a 32-bit data layout.
- Implement the i386 SysV C ABI classifier, including aggregate and stack argument rules.
- Add ELF32 object validation, hosted sysroot/CRT linking, and QEMU/native runtime smoke tests.
- Audit serialization and linker validation code for ELF64-only assumptions.
- Do not add every 32-bit target in this issue.

## Completion criteria

- [ ] A simple freestanding and hosted i686 program emits valid ELF32.
- [ ] `isz`/`usz` are 32-bit for this target and 64-bit targets remain unchanged.
- [ ] Pointer/int conversions reject width loss unless explicit and valid.
- [ ] C ABI edge fixtures pass against a 32-bit C compiler.
- [ ] CI has a bounded compile/link/run contract.

Contributor guide

Open the contributing guide

Research direction

Start by locating the existing 64-bit target specifications, x86 LLVM initialization, ABI classifier, ELF validation, linker paths, and runtime smoke tests. Compare each area with the stated 32-bit requirements, then use freestanding and hosted i686 programs plus C ABI edge fixtures to verify valid ELF32 output, correct pointer widths, conversions, linking, and bounded CI execution.

Written by the indexing model from the issue text.

Assessment

Tech stack
c, linux, rust
Domain
build-system, compilers, operating-systems, testing
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.