Skip to content

Commit

Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
.
Browse files Browse the repository at this point in the history
vbgl committed Mar 13, 2024

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
1 parent b35ea0f commit 8bf88ed
Showing 2 changed files with 15 additions and 2 deletions.
3 changes: 1 addition & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -78,8 +78,7 @@
- Extraction as EasyCrypt code targets version 2024.01
([PR #690](https://github.com/jasmin-lang/jasmin/pull/690)).

- Relaxed alignment constraints for memory and array accesses (opt-in: use
dedicated syntax to flag accesses that may be unaligned)
- Relaxed alignment constraints for memory and array accesses
([PR #748](https://github.com/jasmin-lang/jasmin/pull/748)).

## Bug fixes
14 changes: 14 additions & 0 deletions compiler/tests/success/common/unaligned.jazz
Original file line number Diff line number Diff line change
@@ -6,3 +6,17 @@ fn main(reg u32 x) -> reg u32 {
x = a.[#unaligned 2];
return x;
}

/* This example shows that the unaligned 16-bit access is taken into account
* when computing the alignment for the stack variable. */
#[stackalign=u16]
export
fn instack(reg u32 x) -> reg u32 {
reg u32 r;
stack u8[3] s;
r = 0;
s[0] = r;
s.[u16 1] = (16u)x;
r = (32s)s[u8 1];
return r;
}

0 comments on commit 8bf88ed

Please sign in to comment.