Bug 1959 – ICE(eh.c 41) alloca and Linux exception handling
Status
RESOLVED
Resolution
FIXED
Severity
normal
Priority
P2
Component
dmd
Product
D
Version
D1 (retired)
Platform
x86
OS
Linux
Creation time
2008-03-30T13:04:00Z
Last change time
2014-02-24T15:33:30Z
Keywords
ice-on-valid-code
Assigned to
nobody
Creator
sergey
Comments
Comment #0 by sergey — 2008-03-30T13:04:30Z
// file bad.d:
import std.process;
void main(char[][] argv) {
bool cond = false;
while( cond ) try { } catch { }
execvp( argv[0], argv );
}
// end of file
Compilation error:
sergey:/tmp/eh$ dmd |head -1
Digital Mars D Compiler v1.028
sergey:/tmp/eh$ dmd -release -inline -c bad.d
Internal error: eh.c 41
sergey:/tmp/eh$
Sorry if it is duplicate of #1337 but my issue seem to have nothing to do with threads or memory allocation. This code is useless but I hit the bug with much more code, this is just the minimal version that still triggers compilation error.
Comment #1 by sergey — 2008-04-06T05:09:25Z
Hello, is there anybody here? :)
Comment #2 by shro8822 — 2008-04-07T13:56:45Z
Yes. What do you want someone to say? You found a bug, reported it with an example. About the only constructive thing to be said is, "fixed" and that's not going to happen for a few days at the least (more likely it will be a few releases). No comments means nobody has anything constructive to say, not that you are being ignored.
Comment #3 by sergey — 2008-04-07T18:29:23Z
OK, thanks.
Comment #4 by smjg — 2008-11-20T21:04:50Z
WFM DMD 1.036 Windows. Can you still reproduce under Linux?
Comment #5 by dsimcha — 2008-11-25T13:22:17Z
Ran into this on Linux with DMD 2.20. I'm working on isolating the piece of code that's the problem, but it's definitely still a problem.
Comment #6 by clugdbug — 2009-07-10T00:07:55Z
Line eh.c (41) states:
#if TARGET_LINUX || TARGET_OSX || TARGET_FREEBSD || TARGET_SOLARIS
:
// BUG: alloca() changes the stack size, which is not reflected
// in the fixed eh tables.
assert(!usedalloca);
So this is a known bug.
Comment #7 by clugdbug — 2009-09-13T03:37:17Z
I'm closing this because the original bug has been fixed, and all known test cases pass. Create a new bug if a new test case is discovered. It'll be a different bug, even if it ICEs at the same location.