From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=0.7 required=5.0 tests=BAYES_00,MSGID_RANDY autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 10b6ac,9f5633938c224117 X-Google-Attributes: gid10b6ac,public X-Google-Thread: 103376,9f5633938c224117 X-Google-Attributes: gid103376,public X-Google-Thread: 11038b,9f5633938c224117 X-Google-Attributes: gid11038b,public X-Google-ArrivalTime: 2001-01-31 11:30:12 PST Path: supernews.google.com!sn-xit-02!supernews.com!nntp-relay.ihug.net!ihug.co.nz!news-hog.berkeley.edu!ucberkeley!newsswitch.lcs.mit.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!nntp2.deja.com!nnrp1.deja.com!not-for-mail From: Ted Dennison Newsgroups: comp.windows.x.intrinsics,comp.lang.ada,comp.windows.x.motif Subject: Re: Using Xt intrinsics with Ada? Date: Wed, 31 Jan 2001 19:19:05 GMT Organization: Deja.com Message-ID: <959oeu$s8g$1@nnrp1.deja.com> References: <3A78357A.2BD8C0B1@avitech.de> NNTP-Posting-Host: 204.48.27.130 X-Article-Creation-Date: Wed Jan 31 19:19:05 2001 GMT X-Http-User-Agent: Mozilla/5.0 (Windows; U; WinNT4.0; en-US; 0.7) Gecko/20010109 X-Http-Proxy: 1.0 x72.deja.com:80 (Squid/1.1.22) for client 204.48.27.130 X-MyDeja-Info: XMYDJUIDtedennison Xref: supernews.google.com comp.windows.x.intrinsics:51 comp.lang.ada:4777 comp.windows.x.motif:884 Date: 2001-01-31T19:19:05+00:00 List-Id: In article <3A78357A.2BD8C0B1@avitech.de>, =?iso-8859-1?Q?J=FCrgen?= Grigat wrote: > sockets. The calls are done in Ada by using interfaces to C library > functions. In order to avoid polling we wonder if we can use the event > mechanism of X Toolkit Intrinsics. So we created a task which is > calling a C-routine that itself calls XtAppMainLoop. The main program > is an Ada routine. From the functional point of view this seems to > work. But we recognize a heavy CPU load even there is no traffic at > the connection. I'm missing something here. XtAppMainLoop never returns to the caller. How exactly are you planning on getting the sockets serviced? Are you saying that you hooked a socket servicing routine into an X event somehow? If so, exacty how? Have you tried doing this exact same thing in C-only code? Sometimes I find it useful to remove that particular variable when I'm trying to test something new. -- T.E.D. http://www.telepath.com/~dennison/Ted/TED.html Sent via Deja.com http://www.deja.com/