new(malloc) locks everything in multithreading
tcak via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Fri Oct 24 02:12:56 PDT 2014
On Friday, 24 October 2014 at 08:55:17 UTC, Kagamin wrote:
> Do you see recursive call to malloc in the stack trace?
I further simplified the example:
import std.stdio;
import core.thread;
class ThreadTest{
public this(){
new core.thread.Thread( &threadRun ).start();
}
private void threadRun(){
writeln("It works");
readln();
}
}
void main(){
new ThreadTest();
char[] abc = new char[4096];
}
This is what I see on screen:
http://imgur.com/Pv9Rulw
Same result.
More information about the Digitalmars-d-learn
mailing list