digitalmars.D.bugs - DMD SIGSEGV
- Tiago Gasiba (15/15) Nov 24 2005 I'm not sure if this error has already been posted or not.
- Deewiant (4/22) Nov 24 2005 Confirmed on DMD 0.139, Windows (XP SP2). Gives an "Error: Win32 Excepti...
- Thomas Kuehne (14/26) Nov 26 2005 -----BEGIN PGP SIGNED MESSAGE-----
- Tiago Gasiba (8/17) Nov 28 2005 That is certainly true, but shouldn't there be a much nicer error messag...
- Thomas Kuehne (22/35) Dec 03 2005 -----BEGIN PGP SIGNED MESSAGE-----
I'm not sure if this error has already been posted or not. In any case, here it goes: Compile with DMD 0.139 (Linux) and run the program. It breaks down with SIGSEGV. <snip> int main(){ double[] X; X.length = 2147483120; return 0; } <snip> Best, Tiago -- Tiago Gasiba (M.Sc.) - http://www.gasiba.de Everything should be made as simple as possible, but not simpler.
Nov 24 2005
Tiago Gasiba wrote:I'm not sure if this error has already been posted or not. In any case, here it goes: Compile with DMD 0.139 (Linux) and run the program. It breaks down with SIGSEGV. <snip> int main(){ double[] X; X.length = 2147483120; return 0; } <snip> Best, TiagoConfirmed on DMD 0.139, Windows (XP SP2). Gives an "Error: Win32 Exception". The biggest length that still ran succesfully (or, at least, tried to... I didn't let it finish) was 205496319.
Nov 24 2005
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Tiago Gasiba schrieb am 2005-11-24:I'm not sure if this error has already been posted or not. In any case, here it goes: Compile with DMD 0.139 (Linux) and run the program. It breaks down with SIGSEGV. <snip> int main(){ double[] X; X.length = 2147483120; return 0; } <snip> Best, TiagoThis isn't a bug but a feature of the used system. Required memory: 17179864964 <- 2147483120 * double.sizeof + size_t.sizeof 2 ^ 34 <- 17179864964 2 ^ 34 bytes on a 32bit system are allways a bit difficult. Thomas -----BEGIN PGP SIGNATURE----- iD8DBQFDiTFT3w+/yD4P9tIRAs2mAJ49PvjOCM5cQwQ9J55K1RmrrwvJWwCeIaCA v8tEk4mKxqzFlnJJ7WCiG+U= =1QxA -----END PGP SIGNATURE-----
Nov 26 2005
Thomas Kuehne schrieb:This isn't a bug but a feature of the used system. Required memory: 17179864964 <- 2147483120 * double.sizeof + size_t.sizeof 2 ^ 34 <- 17179864964 2 ^ 34 bytes on a 32bit system are allways a bit difficult. ThomasThat is certainly true, but shouldn't there be a much nicer error message? It is somehow obvious that the program has to break down, but it should report something like "Not enough memory to execute line xxx" or "Memory exhausted at line xxx". Best, Tiago -- Tiago Gasiba (M.Sc.) - http://www.gasiba.de Everything should be made as simple as possible, but not simpler.
Nov 28 2005
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Tiago Gasiba schrieb am 2005-11-28:Thomas Kuehne schrieb:should have been: 17179864968 <- 2147483120 * double.sizeof + 2 * size_t.sizeofThis isn't a bug but a feature of the used system. Required memory: 17179864964 <- 2147483120 * double.sizeof + size_t.sizeof 2 ^ 34 <- 17179864964To fix this open "dmd/src/phobos/gc/gc.d", add the following check to _d_new as well as _d_newarrayi and recompile Phobos. Thomas -----BEGIN PGP SIGNATURE----- iD8DBQFDklOd3w+/yD4P9tIRAv1HAJwJeLOh8zgkEmlgdpZ9ZXkBf3NWeQCfYgD7 FiRKyu46VKCrh+mwQSN29a4= =ThqU -----END PGP SIGNATURE-----2 ^ 34 bytes on a 32bit system are allways a bit difficult. ThomasThat is certainly true, but shouldn't there be a much nicer error message? It is somehow obvious that the program has to break down, but it should report something like "Not enough memory to execute line xxx" or "Memory exhausted at line xxx".
Dec 03 2005