Skip to content

Commit

Permalink
libunwind code movaps xmm, 0xxx0(rsp) is causing misaligned exception (
Browse files Browse the repository at this point in the history
…#1)

but compiler default is 16 byte aligned.
align stack boundary to 8 bytes
default it aligns to 16, but somehow rsp is not 16 byte aligned,
it caused movaps access misaligned(8 bytes not 16 bytes) address.

need to see why rsp is not aligned by 16

Co-authored-by: Yao Zhao <[email protected]>
  • Loading branch information
zhaoyao73 and Yao Zhao authored Jan 18, 2024
1 parent ba98506 commit e0b1d90
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ fn compile_libunwind() {
cfg.flag("-fstrict-aliasing");
cfg.flag("-fvisibility=hidden");
cfg.flag("-funwind-tables");
cfg.flag("-mpreferred-stack-boundary=3");
cfg.define("_LIBUNWIND_NO_HEAP", None);
cfg.define("_LIBUNWIND_IS_BAREMETAL", None);
cfg.define("_LIBUNWIND_IS_NATIVE_ONLY", None);
Expand Down

0 comments on commit e0b1d90

Please sign in to comment.