ARC now capable of custom extra alignment. Ref, closure and seq support. (#15697)

This commit is contained in:
cooldome 2020-10-28 13:00:49 +00:00 • committed by GitHub
commit 0956a99537
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
11 changed files with 273 additions and 77 deletions

View file

@ -1,17 +0,0 @@
discard """
disabled: true
"""
# does not yet work
{.passC: "-march=native".}
type
m256d {.importc: "__m256d", header: "immintrin.h".} = object
proc set1(x: float): m256d {.importc: "_mm256_set1_pd", header: "immintrin.h".}
for _ in 1..1000:
var x = newSeq[m256d](1)
x[0] = set1(1.0) # test if operation causes segfault
doAssert (cast[uint](x[0].addr) and 31) == 0