make stack work

This commit is contained in:
nora 2023-12-23 15:31:15 +01:00
parent e28469fcc0
commit 46e5662aab
15 changed files with 122 additions and 117 deletions

View file

@ -131,8 +131,8 @@ pub struct Statement {
pub enum StatementKind {
Alloca {
result: Register,
size: Operand,
align: Operand,
size: u64,
align: u64,
},
Store {
ptr: Operand,
@ -234,6 +234,8 @@ impl Func<'_> {
}
impl BbIdx {
pub const ZERO: Self = Self(0);
pub fn from_usize(n: usize) -> Self {
Self(n.try_into().unwrap())
}