This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug libgcj/13212] JNI/CNI AttachCurrentThread does not register thread with garbage collector



------- Comment #17 from arno at heho dot snv dot jussieu dot fr  2005-10-23 00:28 -------
I quickly wrote a testcase to illustrate my point (attached jnew.java Makefile
gc-thread-register.cc) :

Compiling and running gives : 

  ./gc-thread-register 
  Starting first thread ...done
  Collecting from unknown thread.
  Abort trap (core dumped)

  (I know I develop and test on freebsd for which boehm-gc-threading is not
Tier-1, but :)

Compiling and running with FAKE_GC_CONFIG (set correct include path in
Makefile) defined gives :

  ./gc-thread-register 
  Starting first thread ...done
  Starting second thread ...done

NB, this does not necessarily explain (for me) why JvAttachCurrentThread()
fails in some situations (as is the essence of this PR), I just thought that
clearing up the interactions between gcj, boehm-gc and thread-lib might help in
nearing down the causes. 

PS, I thought the attachments where just for this note  


-- 

arno at heho dot snv dot jussieu dot fr changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |arno at heho dot snv dot
                   |                            |jussieu dot fr


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13212


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]