Skip to content

Commit

Permalink
Only use general purpose registers, since clang otherwise will use XM…
Browse files Browse the repository at this point in the history
…M registers for passing floats to rust functions that don't expect it

Signed-off-by: Ludvig Liljenberg <[email protected]>
  • Loading branch information
ludfjig committed Jan 31, 2025
1 parent ae7b6fd commit 05dd3cb
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
2 changes: 1 addition & 1 deletion c.just
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ c-flags-release-pe := '/O2 /Gy'

# Elf options
# We don't support stack protectors at the moment, but Arch Linux clang auto-enables them for -linux platforms, so explicitly disable them.
c-compile-options-elf := '-nobuiltininc -H --target=x86_64-unknown-linux-none -fno-stack-protector -fstack-clash-protection -mstack-probe-size=4096'
c-compile-options-elf := '-mgeneral-regs-only -nobuiltininc -H --target=x86_64-unknown-none-elf -fPIC -fno-stack-protector -fstack-clash-protection -mstack-probe-size=4096'
c-include-flags-elf := replace(c-include-flags-pe, '/I ', '-I ')
c-linker-options-elf := '--entry "entrypoint" --nostdlib -pie'
c-flags-debug-elf := '-O0'
Expand Down
1 change: 0 additions & 1 deletion src/hyperlight_host/tests/sandbox_host_tests.rs
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,6 @@ fn pass_byte_array() {
}

#[test]
#[ignore = "Fails with mismatched float only when c .exe guest?!"]
#[cfg_attr(target_os = "windows", serial)] // using LoadLibrary requires serial tests
fn float_roundtrip() {
let doubles = [
Expand Down

0 comments on commit 05dd3cb

Please sign in to comment.