aalhour / aalhour/PyCOOLC

Epic 2: Wire IR into the compilation pipeline (AST → TAC → MIPS)

Ouverte
#18 0 commentaires 0 réactions 0 personnes assignées Voir sur GitHub
Langage dominant
Python
Étoiles
41
Forks
10
Métriques de merge des PR
Aucune PR mergée en 30 j

Description

## Epic 2: Wire IR into the compilation pipeline (AST → TAC → MIPS)

### Goal: IR is not a teaching demo; it actually drives codegen and optimizations.

- [ ] Define pipeline stages explicitly:
- [ ] parse → sema → lower-to-TAC → optimize → regalloc/stack-alloc → emit MIPS
- [ ] Ensure TAC lowering covers all COOL constructs (if not already complete)
- [ ] Write a TAC-to-MIPS code generator (new backend):
- [ ] calling convention (args, return, saved regs)
- [ ] stack frame layout rules
- [ ] object layout / runtime calls
- [ ] string ops (concat, length, substr) correctness
- [ ] Keep current AST-to-MIPS backend temporarily as reference/fallback
- [ ] Add integration tests comparing TAC-path output vs AST-path output (until AST path is retired)

Guide de contribution

Aucun guide de contribution indexé pour ce dépôt

Évaluation

Cette issue n'a pas encore été évaluée.

Recevez les nouvelles issues par e-mail

Un résumé court des issues GitHub adaptées aux débutants.