473,804 Members | 2,711 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Thread Starvation

Hello All,

To preface my question, I'm running python on an embedded PowerPC chip
(8xx), with a host OS of Linux. I'm seeing, in some of my applications,
thread starvation. I can create new threads, however their run methods
are never called. Interestingly enough, threading.activ eCount() and
threading.enume rate() properly return all the threads I've started. Yet
none of them will get their run method called.

The python interpreter we use to run our python scripts is created
programmaticall y in its own thread (f that matters at all).

For quite sometime, I thought this was a memory leak on our side, but
I'm not convinced of that, yet I haven't ruled it out. If it is a
memory leak, it only manifests itself in threading, no where else do we
see strange behavior, and we write quite a few scripts targeted to this
platform.

90% of our scripts have threads that work just fine. It is a small
subset of our scripts that have thread starvation. It is worth noting
that if a script runs into this problem, *all* of the threads starve,
not just a couple of them starve.

Finally, the scripts that exhibit this behavior, always exhibit this
behavior. It doesn't seem to be dependent upon any external conditions.
What I'm curious about is the following:

- Has anyone ever encountered something similar to this?
- What are appropriate ways of debugging this? Are there ways to debug
the interpreter to get more information from it (i.e.: what is causing
it to not call run(), is there some mutex issue, resource issue, etc)?

I realize there are a ton of variables to take into account here, I'm
just looking for some ideas on what might be holding me up.

Thanks so much.

-Brett
Brett Humphreys
Software Engineer
Applied Innovation
Office: 800-247-9482 x2302
Fax: 614-798-1770
Jul 18 '05 #1
0 1207

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
1755
by: FrankEsser | last post by:
Hello! I am not an expert on C++ programming and therefor I have a question: We use a kind of communication server that was written in C++ especially for our company. It just takes incoming socket requests, connects, evaluates incoming data packages and gives them to certain plug-ins adressed in the frame of the data packages. For each data package management an own thread is started. The data packages can arrive faster than the...
7
2770
by: Droopy | last post by:
Hi, I don't understand why sometimes, a loop running in a thread takes much more time than usual. I have a thread that must call each 20 ms a C++ unmanaged function. I made a C++ managed wrapper for calling this function from C# (see below _serialChannel.ItTask ()). It works great but for this timing problem. Here below, the main loop for this thread :
37
8923
by: ales | last post by:
Hello, I have a problem with creation of new thread. The method .Start() of newly created thread delays current thread for 0 - 1 second. Cpu while delay occurs is about 5%. Any idea? Here is code used for measuring:
8
1701
by: Carl Heller | last post by:
If I'm creating a class to do some work that I want threaded out, where's the best location to call ThreadStart? Or does it depend on the nature of the work? a. Call it outside the class, giving it the starting method of the class? b. Have the class create the thread itself? ie: x = new WorkerClass(); ioThread = new Thread(new ThreadStart(x.StartWork));
0
9704
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9571
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10561
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
7608
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6845
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5505
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5639
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4277
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3803
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.