https://issues.dlang.org/show_bug.cgi?id=11435
safety0ff.bugz <[email protected]> changed: What |Removed |Added ---------------------------------------------------------------------------- Summary|Nondeterministic 32bit |-O optimization flag causes |release mode access |invalid codegen |violation | Severity|normal |critical --- Comment #5 from safety0ff.bugz <[email protected]> --- I've managed to reduce it to a test that consistently fails. The reduced test case is posix only (posix with MAP_ANON extension,) but the bug manifests itself on all 32 bit x86 platforms. Disassembly snippet: Here is part of the loop in S.foo(), DMD creates a 4 byte read on <+85>, but it is only valid to read one byte. This causes the segfault. ebx is the loop index and ecx is the pointer to the array. <+80>: mov -0x4(%ebp),%ecx <+83>: mov %esi,%eax => <+85>: pushl (%ebx,%ecx,1) <+88>: push %ebx <+89>: call 0x8070f70 <_D6_114351S13opIndexAssignMFbkZb> <+94>: inc %ebx <+95>: cmp 0x8(%ebp),%ebx <+98>: jb 0x8070f41 <_D6_114351S3fooMFAbZv+65> --
