Win a copy of Testing JavaScript Applications this week in the HTML Pages with CSS and JavaScript forum!

Wanki Ho

Greenhorn
+ Follow
since Feb 18, 2004
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Wanki Ho

Given the opportunity to specialize between one or the other, what would you choose? I'd like to hear the differences between the two in terms of future growth, job prospects, and resistance to offshoring.
16 years ago
Say for example I want to take a thread out of a queue and run it for exactly one second and than stick it back into the queue. How would I do that?
Say I want a thread priority range between 0-127 with a lower number meaning a higher priority. How would I simulate that?
I should have been more specific. It's a Unix CPU process scheduler. I don't know how many different kinds of Unix schedulers there are, but I'm guessing it's the default one for the Unix system. It's a priority based scheduler with 64 different priority levels that goes through each process for a certain time slice and than reinserts them back into the array with a lower priority level based on some algorithm.
I've never programmed anything like this with threads, it's pretty alien to me. I wish I could get my hands on some source code with a few examples of process schedulers.
How do I run a demo to prove my scheduler works? What would I use for threads? So far I'm just using some nonsense worker threads that go through 10,000 iterations of a loop.
How do I give a thread a priority range from 0-64?
The basic data structure I've decided to work with is an Arraylist with 64 circular array queues. I don't know if this is right.
Unix schedulers are supposed to switch threads whenever one with a higher priority becomes available. How do you do that?
Should the scheduler program itself be a thread or a while loop?
I would appreciate any tips.
16 years ago
I have an assignment to write a Unix scheduler in java and I'm not altogether sure about how to go about doing this as our instructor was very vague and didn't give us many specifications.
16 years ago