From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 2744 invoked by alias); 10 Apr 2013 23:18:28 -0000 Mailing-List: contact java-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: java-owner@gcc.gnu.org Received: (qmail 2692 invoked by uid 89); 10 Apr 2013 23:18:27 -0000 X-Spam-SWARE-Status: No, score=-5.2 required=5.0 tests=AWL,BAYES_00,FREEMAIL_FROM,KHOP_RCVD_TRUST,KHOP_THREADED,RCVD_IN_DNSWL_LOW,RCVD_IN_HOSTKARMA_YE,TW_GC autolearn=ham version=3.3.1 Received: from mail-we0-f179.google.com (HELO mail-we0-f179.google.com) (74.125.82.179) by sourceware.org (qpsmtpd/0.84/v0.84-167-ge50287c) with ESMTP; Wed, 10 Apr 2013 23:18:26 +0000 Received: by mail-we0-f179.google.com with SMTP id p43so788496wea.24 for ; Wed, 10 Apr 2013 16:18:24 -0700 (PDT) X-Received: by 10.180.208.47 with SMTP id mb15mr30066006wic.16.1365635904250; Wed, 10 Apr 2013 16:18:24 -0700 (PDT) Received: from [192.168.2.99] (cpc27-cmbg15-2-0-cust220.5-4.cable.virginmedia.com. [86.27.188.221]) by mx.google.com with ESMTPS id dp5sm27811wib.1.2013.04.10.16.18.22 (version=SSLv3 cipher=RC4-SHA bits=128/128); Wed, 10 Apr 2013 16:18:23 -0700 (PDT) Message-ID: <5165F3EB.6080306@gmail.com> Date: Wed, 10 Apr 2013 23:18:00 -0000 From: Dave Korn User-Agent: Thunderbird 2.0.0.17 (Windows/20080914) MIME-Version: 1.0 To: GCC Java CC: Bryce McKinlay , Andrew Haley Subject: Re: Usage of _Jv_AttachCurrentThread, _Jv_AttachCurrentThreadAsDaemon, _Jv_DetachCurrentThread. References: <51645BD5.3090906@gmail.com> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-SW-Source: 2013-04/txt/msg00003.txt.bz2 On 10/04/2013 10:34, Bryce McKinlay wrote: > On Tue, Apr 9, 2013 at 7:20 PM, Dave Korn wrote: > >> I could fix this by either adding a !defined(GC_WIN32_THREADS) in the same >> way as Solaris disables these functions, or I could add an implementation of >> the functions in boehm-gc for Cygwin, which is posixy and pthread-based. > > As Andrew said, these are used by the JNI (& CNI) "invocation API", > which allows calling into Java code from a non-Java app. > > It might be worth checking if newer versions of the GC already have > improvements here for Cygwin. libgcj's copy of boehm-gc is very old > and we really ought to update it! Yes indeed! It turns out that upstream has implemented them since 7.0alpha2 (now at 7.3alpha4). Upstream now includes a new support library, libatomic_ops, that is licensed under a combination of GPLv2 and a custom "MIT-style" licence. Is that likely to be any problem? >> Also on the same topic, would there be any value added by providing Cygwin >> implementations of GC_suspend_thread, GC_resume_thread and >> GC_is_thread_suspended, which are called from _Jv_SuspendThread, >> _JV_ResumeThread, _JV_IsThreadSuspended in boehm.cc and currently #if'd out by >> a test on GC_WIN32_THREADS? > > Well, I don't think anything in libgcj really uses these. They might > be useful as part of a debugging interface. Good to know, thanks to both of you for the information. cheers, DaveK