CAP/MiniC/README-codegen.md

53 lines
1008 B
Markdown
Raw Permalink Normal View History

2024-10-06 19:58:11 +02:00
# MiniC Compiler
LAB4 (simple code generation), MIF08 / CAP 2023-24
2024-10-06 19:58:11 +02:00
# Authors
2024-10-21 23:10:10 +02:00
Augustin LUCAS
2024-10-06 19:58:11 +02:00
# Contents
# Test design
# Design choices
2024-10-21 23:10:10 +02:00
Booleans are implemented as integers behind the scenes, but type-checking before compilation disables any casting mechanism.
As for the previous lab, the Fortran-like for-loop extension has been implemented.
2024-10-06 19:58:11 +02:00
# Known bugs
# Checklists
A check ([X]) means that the feature is implemented
and *tested* with appropriate test cases.
## Code generation
2024-10-21 23:10:10 +02:00
- [x] Number Atom
- [x] Boolean Atom
- [x] Id Atom
- [x] Additive expression
- [x] Multiplicative expression
- [x] UnaryMinus expression
- [x] Or expression
- [x] And expression
- [x] Equality expression
- [x] Relational expression (! many cases -> many tests)
- [x] Not expression
2024-10-06 19:58:11 +02:00
## Statements
2024-10-21 23:10:10 +02:00
- [x] Prog, assignements
- [x] While
- [x] Cond Block
- [x] If
- [x] Nested ifs
- [x] Nested whiles
2024-10-06 19:58:11 +02:00
## Allocation
2024-10-21 23:10:10 +02:00
- [x] Naive allocation
- [x] All in memory allocation
2024-10-06 19:58:11 +02:00
- [ ] Massive tests of memory allocation