www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 21474] New: ICE with core.simd and -O ("Illegal Instruction")


          Issue ID: 21474
           Summary: ICE with core.simd and -O ("Illegal Instruction")
           Product: D
           Version: D2
          Hardware: x86_64
                OS: Windows
            Status: NEW
          Severity: normal
          Priority: P1
         Component: dmd
          Assignee: nobody puremagic.com
          Reporter: aliloko gmail.com

-------- test3.d --------

import core.simd;

struct long1
    long[1] arr;

int4 to_m128i(long1 a)
    long2 r;
    r[0] = a.arr[0];
    return cast(int4)r;


Build with: dmd -O -m64 test3.d

DMD 2.094.2 returns -1073741795
DMD 2.088.0 has a bit more info and says: object.Error (0): Illegal Instruction

The bug disappear with -O left out.

Dec 11 2020