SGI: Development

Parallelization of Codes on the SGI Origins - Page 2

Geoman wrote: So it would be wise to remove the dual R12K and insert a single R14K 600. Because I too often see 49% CPU usage in top :-/

Sadly, a lot of the time that's probably true :(

foetz wrote: the number of daily use programs that can utilize more than one cpu or core is pretty much zero. one of the main reasons why multi-core cpus for the consumer market are a joke

I shall impersonate ... a developer. Come, enter into my imagination, and see him: Boney, hollow faced, eyes that burn with the fire of inner vision. He conceives the strangest project ever imagined ... a browser that works !

The thread that starts the program immediately spawns off two or three threads to do the work, then returns to become a listener thread, always alert to the user's requests. One worker thread draws the windows, another starts an xulrunner process to display a web site. Maybe there are five tabs open : the main thread creates five more processes to display more sites. Never does connecting ... connecting ... connecting ... lock the user out of control. Always he can go to a different tab, view a different site while waiting, hunt through the bookmarks. Six processes, twenty threads, four cpu's, we're rockin' and a-rollin, no thumb-twiddling required ! One site of shitty code, that tab crashes, who cares ? Just displays an empty window ... 4 gigs of memory in this box ? Good, let's use 'em all ! Peg them cpu meters ! All of them !

Oh wait. Do I hear the cuckoo singing in the cuckooberry tree ?
he said a girl named Patches was found ...
Oh wait. Do I hear the cuckoo singing in the cuckooberry tree ?
But isn't this the way all modern browsers work? I mean, like safari and chrome and IE... I don't use the latter two but safari spawns a couple processes per tab/window each with a dozen or so threads and for the most part the different tabs don't have any performance affect on each other. I know chrome works the same way and IE tries hard to keep up.

For example, I can have a few tabs open here, including a pdf, a bunch of misc. crap, and some HD flash video on a separate screen. These things have nothing to do with each other. Even if the flash video crashes or buffers/stutters (which it does on occasion) the other windows keep working.

The way I understand it from a layperson's perspective, is that with modern systems making separate processes and threads within processes is relatively inexpensive so it is better to just spin off as many as possible (within reason) and let the OS sort out the scheduling. This makes sense for most 'desktop' interactive programs such as a web-browser. It may not make sense for NASA supercomputers. :P
You eat Cadillacs; Lincolns too... Mercurys and Subarus.
In FF3 and 2 on IRIX there is this only thread that stalls CPU 0 -- and that's a pity.
:Octane2: 2xR12000 400MHz, 4GB RAM, V12
SGI - the legend will never die!!
yeah that cheap yosemite monitor is how a browser process tree could be made better. but only at first sight because that still won't speed up single pages but only adds some failsafe and you can load pages in parallel each page taking one cpu ... whoever does load multiple pages at the same time :P

what i'd like to have is all cpus working on the same page because otherwise you have no speedup
r-a-c.de
Recovering a closed session will load multiple pages at the same time.

A single page/tab can be accelerated by having multiple processors available to Safari today. Not sure if there are multiple threads for the layout engine and javascript interpreter, and you could possibly get something there - but now we're talking about ghz cpus and why bother - your biggest pain is slow js, badly written js, congested or slow networks and badly written or busy servers.

Back to multiple process/thread for that modern Safari, since flash runs in it's own process your flash ads and the js/layout engine are separate.
:O3000: :Fuel: :Tezro: :Octane2: :Octane: :Indigo: :Indigo: :Indigo: :O2: :1600SW: :Indigo2: :Indigo2: :Indigo2: :Indigo2IMP: :Indigo2IMP: :Indy: :Indy: <--challenge S
On one of my machines I decided to do a clean install when I upgraded to Yosemite and I had to experience the internet without adblock for a few minutes until I realized what was wrong.. Some of my favourite sites became unusable without it.

Multi-core CPUs are very important for games. And a lot of games run in the browser nowadays. Me and the wife like to play shadowgun * and while we both use the dedicated mac and windows programs respectively, I would say 75% of the players play through facebook (the browser). Why? Well, I don't have a facebook but I'm guessing it (a) posts your scores and ranking to your friends and (b) you don't have to create a seperate account. (Shadowgun tells you what system each player is using in the rankings after each match)

* She says I'm too good at Unreal since I grew up with it (playing since the first one came out) and refuses to play with me anymore :lol:

I think the gaming advantage is lost with more than 4 cores but it most game engines make good utilization of two or three. I think a lot of people here still think a web-based game can't be a full-on 3D shooter, but that's not true anymore. I think it's silly but there sure are a lot of gamers there.

Another place lots of CPU chutzpah is needed in the browser is video streaming. I like NHL gamecenter live. There is an xbox app but they do regional blackouts a lot so of course you will need a "real computer" that can log on to a VPN and it doesn't seem worth it to try and set that up with the xbox. Unlike watching a film, cartoon, or even most other sports example football if your hockey stream drops a few frames and switches quality (i.e. down to 720@30fps) you WILL notice it... the puck disappears. :D



The JS in safari, chrome, IE and probably even firefox is multithreaded but it doesn't seem to make much difference, there is good unobtrusive JS that won't make a dent in CPU usage, and bad poorly written JS that will hang up the interpreter regardless of how good it is. Well written and efficient JS that is used for useful work and requires lots of computational power is non-existent. Except for synthetic browser benchmarks.

foetz wrote: yeah that cheap yosemite monitor is how a browser process tree could be made better. but only at first sight because that still won't speed up single pages but only adds some failsafe and you can load pages in parallel each page taking one cpu ... whoever does load multiple pages at the same time :P

what i'd like to have is all cpus working on the same page because otherwise you have no speedup

In all fairness, the networking process and internal database are both multithreaded. It is just a different method of doing things. If you have a single page with a flash or js all of that is separate multithreaded processes. I think it is better even if you have a single CPU because one bad process is not going to wreck the whole program.
You eat Cadillacs; Lincolns too... Mercurys and Subarus.
guardian452 wrote: But isn't this the way all modern browsers work?

In a word, no :D I am green with envy. Fireflop on Irix and a fairly current one on Windows will lock up tighter than a miser's ass holding a nickel if you get two or three tabs taking a while to load.

connecting .... connecting .... connecting ...

No ! jerkface, you are never going to get fonts.googleapis.com. Ever ! So give it up, bitch !

I really hate that thing. Too bad Swarfari doesn't work on Irix.

safari spawns a couple processes per tab/window each with a dozen or so threads and for the most part the different tabs don't have any performance affect on each other.

Five points to Apple for being at least as smart as the average sixth-grader.

For example, I can have a few tabs open here, including a pdf, a bunch of misc. crap, and some HD flash video on a separate screen. These things have nothing to do with each other.

4 gb of memory ...

Code: Select all

fool 2% Not enough space atcheckpoint/atrestart failed to malloc
libexc(10973): FATAL ERROR __exc_new_cache: unable to allocate a new cache
WARNING: core: firefox-bin: PID 10973, failed to write a  text area (core file deleted)
moz_run_program[36]: 10973 Abort


The way I understand it from a layperson's perspective, is that with modern systems making separate processes and threads within processes is relatively inexpensive so it is better to just spin off as many as possible (within reason) and let the OS sort out the scheduling.

'Modern' as in 1993 ? Read OS/2 programming docs : it's nice to know that someone besides IBM finally figured it out but 'modern' ? Only in geological terms :P

japes wrote: Recovering a closed session will load multiple pages at the same time.

You mean right after firefox crashes ? Yes :D Also, if you are doing a search it's nice to rmb and open several tabs at once. The flop can handle maybe two or three tabs, after that you may as well go out to lunch while you wait. I'm talking on Windows here also, btw. And you can't even open another tab to do something else while you wait. It's locked up solid.

You probably don't see that problem because your innernet is fast but our overseas is piped in through a soda straw. S-l-o-w.

A single page/tab can be accelerated by having multiple processors available to Safari today.

That's nifty. I guess they finally got over cooperative multi-tasking ?

foetz wrote: ... how a browser process tree could be made better. but only at first sight because that still won't speed up single pages but only adds some failsafe and you can load pages in parallel each page taking one cpu ... whoever does load multiple pages at the same time :P

I do. Or try to, anyhow. It's a convenient search technique, especially if your connection is slow. Everybody has different needs, of course, and while speedup on a single page would be great, even a couple degrees of separation between other loading pages would be a big improvement.

I would like to know why some pages, e.g. duckduckgo search returns, are so slow to scroll ? I mean as in s -- l --- o -- w. It's just text, what's up with that ?

what i'd like to have is all cpus working on the same page because otherwise you have no speedup

Would be nice but I'll accept doing more things in parallel without locking up for the present. There's more quad-core cpus out there than Carter's Little Liver Pills but we're still stuck in Windows 3.1-land :(

People have all these methods for "parallelizing code" but if the underlying design of the program is junk, what good do all the tricks do ?

... bad poorly written JS that will hang up the interpreter regardless of how good it is. Well written and efficient JS that is used for useful work and requires lots of computational power is non-existent. Except for synthetic browser benchmarks.

No-Script. I guess I am extreme but so sick of crap Javascript that in general, it's turned off entirely. Once in a while I'll want something bad enough to turn it on temporarily but mostly, if it uses javascript, screw it. Go somewhere else.

I think it is better even if you have a single CPU because one bad process is not going to wreck the whole program.

Yeah, well, Fireflop needs a serious makeover. It worked a lot better when it was Netscape 3.0 :(
he said a girl named Patches was found ...
guardian452 wrote: Multi-core CPUs are very important for games. And a lot of games run in the browser nowadays. Me and the wife like to play shadowgun * and while we both use the dedicated mac and windows programs respectively, I would say 75% of the players play through facebook (the browser). Why? Well, I don't have a facebook but I'm guessing it (a) posts your scores and ranking to your friends and (b) you don't have to create a seperate account. (Shadowgun tells you what system each player is using in the rankings after each match)

* She says I'm too good at Unreal since I grew up with it (playing since the first one came out) and refuses to play with me anymore :lol:

I think the gaming advantage is lost with more than 4 cores but it most game engines make good utilization of two or three. I think a lot of people here still think a web-based game can't be a full-on 3D shooter, but that's not true anymore. I think it's silly but there sure are a lot of gamers there.

Another place lots of CPU chutzpah is needed in the browser is video streaming. I like NHL gamecenter live. There is an xbox app but they do regional blackouts a lot so of course you will need a "real computer" that can log on to a VPN and it doesn't seem worth it to try and set that up with the xbox. Unlike watching a film, cartoon, or even most other sports example football if your hockey stream drops a few frames and switches quality (i.e. down to 720@30fps) you WILL notice it... the puck disappears. :D

haha okay, for members of the "worst resources wasters" list you can never have enough of whatever :P

If you have a single page with a flash or js all of that is separate multithreaded processes.

so js runs on one cpu and the page rendering on another?

hamei wrote: No-Script. I guess I am extreme but so sick of crap Javascript that in general, it's turned off entirely. Once in a while I'll want something bad enough to turn it on temporarily but mostly, if it uses javascript, screw it. Go somewhere else.

exactly the same here :D
r-a-c.de
hamei wrote: 'Modern' as in 1993 ? Read OS/2 programming docs : it's nice to know that someone besides IBM finally figured it out but 'modern' ? Only in geological terms :P


No, modern as in anything available today. Of course your beloved OS/2 did it first, we get it. IBM brought out the T220 monitor fifteen years ago but it is only recently that we can get 2880x1800 in a macbook. It's the only "trickle down economy" that actually makes sense.

The point was not to show how superior apple/safari is to firefox but how awful firefox is compared to even internet explorer, which tries to behave similarly to safari/chrome even if it can't always succeed (a tab has crashed and all pages must be reloaded. OK?)

Just because Irix users have no choice does not mean that all web browsers are awful. I think the amount of work that has been put into keeping firefox running on irix is commendable, but Irix was never really meant for web browsing or anything "consumer oriented" in the first place so let's not kid ourselves. It was the same story 8 years ago. Irix was not meant for the web, there is no good browser, sites are too bloated, etc. Modern websites may be in sad state of affairs but fireflopping around in them is not going to make you any happier.
You eat Cadillacs; Lincolns too... Mercurys and Subarus.
guardian452 wrote: No, modern as in anything available today.

Could we use the word "current", then ? Modern does not mean the same thing.

(btw, OS/2 is available today, with a service contract, even)

guardian452 wrote: Of course your beloved OS/2 did it first, we get it.

Okay, let's switch horses :

http://www.crazyontap.com/topic.php?TopicId=11674

Mickey isn't the only one that doesn't understand a desktop interface and the listener-thread concept is not "modern" at all :D

An interesting counterpoint to the article at the top :

IJPP04_Corbalan.pdf
(194.5 KiB) Downloaded 11 times


One thing that seems entertaining : in a desktop one problem is scheduling threads/ processes for the limited number of cpu's. In this article they discuss how many processors to assign to the number of available threads :P

Irix was not meant for the web

I'm going to get the popcorn started and watch this :D
he said a girl named Patches was found ...
guardian452 wrote: Modern websites may be in sad state of affairs but fireflopping around in them is not going to make you any happier.

sadly it doesn't make one happier with any browser on any machine. bloated crap is bloated crap no matter from where and how you look at it :P

doesn't mean of course that the mozilla stuff couldn't be more suited to today's hardware. for years now every cheap supermarket brand peecee comes with a multicore chip but the vast majority of typical home user stuff i've seen doesn't make use of them. or at least not in a way that'd make a proper difference
r-a-c.de
hamei wrote:
Irix was not meant for the web

I'm going to get the popcorn started and watch this :D


OK, let me rephrase that. Irix's web browser never evolved along with the rest of them because SGI's customers did not require it. Now we are stuck with firefox because there are so few brave souls left to work on it, the effort required to say port chromium to irix would be near impossible.

If I ever won the lottery I would be willing to fund such a project :D

Irix itself is of course just as capable as any other system if not more capable but without a browser... yeah I don't want to devolve into that thread again :roll:
You eat Cadillacs; Lincolns too... Mercurys and Subarus.
guardian452 wrote: OK, let me rephrase that. Irix's web browser never evolved along with the rest of them because SGI's customers did not require it. Now we are stuck with firefox because there are so few brave souls left to work on it, the effort required to say port chromium to irix would be near impossible.

I think that's revisionism :D

Remember that the Indigo was the "Song and Dance Machine" ? And Clark's plan was to replace command-line computing with graphics ? The set-top box was another of his schemes ? Irix still installs a web server and home directory for users to share their nekkid photos via the web ?

In fact, when we had more people, nekoware was more current than many Linux distros. We had Fireflop 2 before a lot of package suppositories did.

Unfortunately, we've dwindled :( Lost dexter1 to online gaming and joerg just disappeared in the night, leaving his family to fend for themselves. Nuthin' left here now but us poor orphans what were too dumb to get off the sinking ship :(

About the original topic, thanks Geoman for bringing that out .... I've always wondered why our parallelizers think "check the number of cpu's then make that many threads." It seems bass-ackwards to me. Open top or pstree for five seconds ...

Code: Select all

IRIX64 urchin 6.5 IP35         load averages: 0.17 0.15 0.02                 11:46:28
65 processes:  64 sleeping, 1 running

Maybe those 2p you just found are doing some other stuff ! So where did they get this weirdness ? I could see if they checked for # of processors then did (p-1) threads but no one does.

Well, here ya go. Read these papers on Big Silicon and they all assign threads by the number of processors. But Big Silicon has 16, 32, 128, 256, 512 p ! And their system overhead is about the same as on an Indy ! Totally different situation. What's amazing is that application programmers can't figure out that a 512p Origin 3900 is not the same as a 2p Octane2.

So, developer question : I had a thought :idea: One real hassle with fireflop is that it becomes unresponsive so easily. That problem was solved decades ago by IBM and BeOS both. How difficult would it be to jack up the front end and install a roll bar ? The trick with BeOS and OS/2 both is that the main thread immediately opens worker threads to run the application, while the main thread becomes a listener thread. Why can't we modify Fireflop code in the same manner ? Take the main, spawn off a thread to become what would normally be the current fireflop, and let the initial main thread stick to listening for user input ?

Is that a feasible change ? It wouldn't fix any of the major problems but at least the damn thing wouldn't go deaf, dumb and blind on you while it was waiting for spyware.google.com ... .
he said a girl named Patches was found ...
:Octane2: 2xR12000 400MHz, 4GB RAM, V12
SGI - the legend will never die!!