Comment #0 by john.loughran.colvin — 2013-10-28T11:50:29Z
The following program segfaults, with or without the __gshared:
import core.simd;
__gshared long2 v0;
__gshared long2 v1;
void main()
{
v1 = v0;
}
Comment #1 by john.loughran.colvin — 2013-10-28T12:20:12Z
I'm not sure where the initial problem is, but by the time we've got down to machine level we get this:
0x425f74: movdqa 0x231454(%rip),%xmm0 # 0x6573d0
0x425f7c: movdqa %xmm0,0x231454(%rip) # 0x6573d8
Which is clearly not ok. For a start, long2 isn't 8 bytes wide. The segfault is probably a GP from the ensuing misaligned store.
Comment #2 by john.loughran.colvin — 2013-10-29T01:15:56Z
Pretty sure it's not a backend issue as the same happens with gdc
Comment #3 by ibuclaw — 2013-10-29T02:17:43Z
I can't reproduce the segfault on gdc...
Disassembly:
movdqa 0x0(%rip),%xmm0
movaps %xmm0,0x0(%rip)