Bug 8966 – ICE(cgcod.c) when passing cfloat argument with indirection

Status
RESOLVED
Resolution
FIXED
Severity
normal
Priority
P2
Component
dmd
Product
D
Version
D2
Platform
All
OS
Windows
Creation time
2012-11-06T00:32:00Z
Last change time
2013-07-20T20:29:14Z
Keywords
ice
Assigned to
nobody
Creator
r.sagitario

Comments

Comment #0 by r.sagitario — 2012-11-06T00:32:43Z
Trying to compile a Win64 debug version of druntime with current githead, I get an ICE when compiling druntime/src/rt/typeinfo/ti_Acfloat.d A reduced test case is module test; void foo(cfloat x) { } cfloat[] a; void main() { foo(a[0]); } building with "dmd -m64 test.d" yields "Internal error: .\backend\cgcod.c 561" This does not happen when I compile with -m32 or if I use cdouble or creal or if I pass a cfloat that is not read from an array. With optimizations, I get "Internal error: .\backend\cgcod.c 188". I don't know if this applies to other OS aswell, maybe issue 6772 is related.
Comment #1 by github-bugzilla — 2012-11-14T22:08:46Z
Commit pushed to master at https://github.com/D-Programming-Language/dmd https://github.com/D-Programming-Language/dmd/commit/10eefc3f5799585d618da90a595d158a22ca5e95 fix Issue 8966 - ICE(cgcod.c) when passing cfloat argument with indirection
Comment #2 by github-bugzilla — 2012-11-16T13:49:26Z
Commit pushed to dmd-1.x at https://github.com/D-Programming-Language/dmd https://github.com/D-Programming-Language/dmd/commit/b319cb6f48ba7a00e9bbd41e42e6ac1d0f99e1e7 fix Issue 8966 - ICE(cgcod.c) when passing cfloat argument with indirection
Comment #3 by bugzilla — 2013-07-20T12:20:53Z
Comment #4 by bearophile_hugs — 2013-07-20T12:58:54Z
But cfloats are deprecated. Isn't it _much_ better to focus the development/debugging efforts on features that are not deprecated?
Comment #5 by github-bugzilla — 2013-07-20T20:29:14Z
Commit pushed to master at https://github.com/D-Programming-Language/dmd https://github.com/D-Programming-Language/dmd/commit/dc1ca1e958f8b093be3b09dc749254adc6079728 Merge pull request #2370 from WalterBright/test8966 add missing test case for Issue 8966