Non DC-able problems?

Status
Not open for further replies.

Hat Monster

Ars Legatus Legionis
47,680
Subscriptor
Complex problems that have a lot of interaction between all aspects.
Sounds like F@H to me.

What is not helped by DC are real-time computations. DC has to be, for the most part, timeless. SETI@Home don't care if they get the data back tomorrow or next month. It's still added to the database and still potentially useful.
Simulating tomorrow's weather, for instance, has to be done quickly. DC won't help you here.

H@
 

hiner112

Smack-Fu Master, in training
98
Well, AI is one of those things that generally would fit the bill, in that disparate parts of the knowledgebase/thinking structure would generally need to communicate fairly often with each other on a time sensitive basis. Artificial life on the other hand would probably benefit from the periodic isolation so that the systems and agents could differentiate/evolve without the outside population contaminating the gene pool.

Weather, as Hat mentioned, is another excellent example since any piece of data can have a measurable impact on the end product, or even the next instant, the data and computations for any stage has to be in before the next stage can begin.


F@H cheat to get it done though. They use a reasonable simplification (treating non-local groups of atoms as one e-field that doesn't move much), and an educated guess (if all local atoms are at a minimum energy level and all groups are at a minimum with respect to each other then the entire thing is at a minimum) to be able to get anything done. This is ok for the inverse square laws on really short time scales but, for stuff that astronomers do, this would not work nearly as well.
 
DC works very well for problems that are computationally limited as opposed to communication limited. You also have the restriction that the problem being worked on must be extrememly parallelizable (yeah, I just made up a word) as well.

Just think about what a DC-type compute engine offers. High CPU power, limited and potentially very delayed communication between nodes. To be DC-able a project has to find ways to cope with those restrictions. Many problems cant, otherwise companies like IBM would've shut down their supercomputer divisions long ago.
 

Hat Monster

Ars Legatus Legionis
47,680
Subscriptor
It doesn't necessarily need to be parallel. SETI@Home, for instance, is sequential.
What they actually do is cut up the sequential data sets and process them in parallel.

It's the lack of dependencies we need to look at. SETI@Home has no dependencies on previous data, even though it's not parallel - if it was parallel, it could be very easily multithreaded.

RC5 also works non-parallel, the keyspace needs to be checked sequentially (or randomly). You can't check two keys on two CPUs to accelerate the process, each CPU works on it's own key.

A semi-parallel project could be GIMPS. Each LL test is totally independent of any other LL test but is also a totally seperate entity, the only common ground being that it is processed in the same way. The LL test itself could be multithreaded (if my understanding of the algorithm is correct).

A good DC project may not be parallel but absolutely has to have no dependencies on other blocks of data. It also must be able to cope with extremely high latency - it could be weeks before the data gets back.

A true parallel project wouldn't work very well for DC, really. The seperate "lines" would interdepend quite a lot in the real world so, for example, parallel "line" A may have to wait for a result from parallel "line" C before it can continue. The latency of internet distributed computing would render the project highly inefficient.

H@
 
You know, there's a large and probably still growing academic literature on this subject.

When I was going to grad school, I was required (sensibly enough) to take some seminar work.

At least half of these would be on topics recognizable here.

Then, it wasn't DC as we know it today. It was on the lines of "Gee, we got all these cheap PCs and Unix boxes -- I wonder how we can use them on stuff that today requires big SMP boxes to solve."

Extending that work to our form of DC is a natural.

Hat has it pretty good, actually. The real question gets down to the frequency of communication and the amount of bits you have to shift between them when you do communicate.

Take matrix multiplication. If you do things the dumb, straightforward way, I don't see how it could parallelize well. This is true even if you do the classic pre-computer-known tricks like dividing each matrix into four hunks and so on.

But, apparently, someone has figured out algorithms that overcome the more obvious means and so decrease the communications to the point where I have read claims (though I haven't validated them in detail) that matrix multiplication now parallelizes very well.

Linux contains this interesting tool called "pvm" which is a way to do a kind of localized "distributed computing" between computers on the same local network. You have to modify the program a little bit, but not as badly as you think, to expose it to PVM. I used it in grad school for a couple of "toy, learn about it" kinds of projects.

It seems a very plausible choice for a wide variety of problems and that would imply DC works for a broad variety of problems.

Here's a problem which fails the communications test, but would be otehrwise good for DC: Chess.

Unless you are playing postal chess with fairly relaxed rules, the issue isn't that the problem at hand can't be distributed -- it can. It isn't that there are lots of interdependencies -- you need not have all that many, especially if your method doesn't prune all the way up to the top very often.

No, the real problem is that you have to get the answer back in a reasonable amount of time to meet typical tournament time limits, which means the distributed units would have to communicate more and expand new board positions less.

In another related sense, F@H is at the limits in the same way on DC. If you return units frequently, the designers tell me, you can do a mini-max like prune and get rid of scheduled crunch which you learn is futile from a few favored incoming units. However, there must be some pragmatic minimum unit of crunch (they've adjusted its size somewhat) to prevent you from getting into communications overload whereby everyone is looking all the time to abort what's going on or to download new, very short duration WU to replace the current, short duration WU. At some point, you have to let some minimal unit of crunch happen to prevent communications chaos, even if it greatly increases the overall DC crunch compared to some theoretical ideal.
 
H@: The "parallelness" of an algorithim has nothing to do with the interdependance of the parallelized threads. And the fact that a problem can be looked at sequentially doesnt mean it isnt also a parrallel problem. Seti is pretty straightforward signal-processing. I know several very large companies building signal processing chips for your cellphone, MP3 player and other devices that would be very disheartened to learn that signal processing is a serial task. ;) And as far as RC5 is concerned, only nutjobs try and do brute-force cracks sequentially. :D

But you're right in that communication is the bigger restriction in DC.
 

Hat Monster

Ars Legatus Legionis
47,680
Subscriptor
I like to think of it in terms of my own (totally independent, I didn't even know what 'distributed computing' meant) first foray into this area.

I had two computers. One was an Amiga1200, with a 28MHz 68020. The other was an Amiga3000 with a 33MHz (overclocked) 68030. They both had synchronous 68882 FPUs. For the time, they may have well been SGIs, they were quite powerful.

I preferred to model in Lightwave on the 1200, since it had better video capabilities. I'd usually render on it too, perhaps fifty frames made to run at 12.5FPS. This would often take entire weekends, especially when I started making underwater scenes with various reflections and murkiness. I'd already cut down the resolution to quarter PAL with no overscan (320x256) and halved the framerate.

It hit me, I could render on both computers if only I could synchronize them - these was the days before software licensing, when you bought software and could install it on as many boxen as you had non-commercially.

If I rendered even frames on the 1200 and odd frames on the 3000, I'd more than halve the time, since the 3000 had better RAM bandwidth and a higher clock frequency.

I refined this technique massively using ARexx (incredible macro language, systemwide) and ParNet (parallel port networking, mapped drives) to get Lightwave on the 1200 rendering the next frame after the one currently on the 3000, introducing interdependencies. The last script I had even compiled the frames (using PPaint) into an animation and saved it out.
This, perhaps would equate to the multiple cores in RC5 and ECCp, each one optimized further until they're peaking at the best performance a given CPU is capable of.

This is the model DC project now I think about it. I dealt with totally independent data, each frame, and I was extremely CPU limited. Communications required between the two machines were negligible, before I started using ARexx all I did was render odd and even, just squirting the LWS files over. All I then had to do at the end was compile them into an IFF ANIM7 and I had the finished product. This would be the central server of a DC system, co-ordinating the data and databasing it - I just did it manually.
Latency was not an issue at all, since frames took many hours to render and weren't really on a deadline. It just came down to how much CPU power I could throw at it. If this isn't the basic procedure behind every DC project I can think of, then I'll be damned. Hehe, I should have patented the technique.

It shows that for a managable DC project, the major bottleneck should always be CPU power. If it's bottlenecked elsewhere, such as indexing data or aquiring data, then it won't be as efficient or even possible. SETI@Home's bottleneck is now data aquisition, but it didn't used to be. The real best model projects are those where massive calculations are required on tiny amounts of data, these would be RC5, GIMPS or the render farm described above, where barely any data transfer goes on at all. Other projects will eventually become bottlenecked in other areas. SETI@Home deals with rather large data transfers, it's become bottlenecked both in server bandwidth and, since it has so much CPU power, data aquisition. Hence, adding CPUs to SETI@Home will not increase the effectiveness of the project.

From here we can determine what our "ideal" DC project would be.
- Negligible (compared to network bandwidth) data transfer
- Massive (or endless) amounts of data to be processed
- Fiendish processing required
- Client able to be deployed anywhere by anyone
Such a project will never reach the stage where adding more CPUs does nothing to the project's effectiveness.
Real world projects are never, by definition, "ideal".
RC5 has reached the point that it will be over soon, it's also ineffective at managing network bandwidth, so has distributed network load also.
SETI@Home is discussed above.
GIMPS is perhaps the closest we'll ever get. The data to be processed is far beyond the capabilities of the CPUs running it, often taking timescales in the order of years. The client is small, unobtrusive and quite friendly. The bandwidth requirements are absolutely tiny - the actual data is smaller than the HTTP header it's transferred with.

Future projects will probably aim themselves at higher bandwidth needs. Data sizes will deviate away from being as small as possible into multimegabyte chunks, which will be necessary since CPUs will be powerful enough to show no mercy at all to the small chunks we work on today - I estimate a Clawhammer at 2GHz will complete a SETI@Home unit in under two hours. Large L2 and high bandwidth Sledgehammers should see the one hour mark being broken again.
Future projects will need to be much more fierce on the CPU or face network meltdown.

H@ - Keycount+++
 

Hat Monster

Ars Legatus Legionis
47,680
Subscriptor
In the big scale of things, you can do all four at once. Just use four computers.
Doesn't mean the problem is parallel, just means you're chopping it up into smaller problems and working on them in parallel.

If it was parallel, then perhaps by doing 1,000, you'd also half complete 16,000. Sure, do the crunching four blocks at a time (vector processing), you're still sequentially processing it out of the pool of, say, fifteen million blocks. Vector processing and parallel processing are somewhat independent (Larry?).

H@
 

Hat Monster

Ars Legatus Legionis
47,680
Subscriptor
Here's how I'm classifying things, but a real DC project is more likely to be random rather than in-order.
dc.gif


The first four are all in-order, the last being random.

H@
 

riskin

Ars Praefectus
3,125
Subscriptor++
Yeah I know what you mean. Standing on the shoulders of giants, as it were. I read and understood most of (I'd say all, but I'd probably be wrong) A Brief History of Time, I understand Relativity, Quantum theory, etc. for the most part. People can talk about these things in a variety of ways, and I can follow and participate in the conversation or debate. But never in a million years could I have come up with any of it. I'm just glad there are giants around.
 
only nutjobs try and do brute-force cracks sequentially

True in the grand sense only.

I have studied cryptography, off and on, since the '60s.

There is a marginal value (especially for the pointy-headed boss types) in making actual demonstrations of brute force cracks. For anyone else, the "demo" mode of RC5 is enough demonstration.

But, it is still a valuable upper-bound measure. Any serious attack of a modern system is going to contain large brute-force elements.

There is something called "differential cryptanalysis" that renders the original DES algorithm vulnerable in only about 2 to the 47rd operations (down from the 2 to the 56th). It requires some very grand assumptions about what is known compared to simple brute force, but there could be cases where this is or could become known to an attacker. See:RSA FAQ page on block ciphers for more. It appears that the most practical attack against DES remains brute force.

[This message was edited by Larry Loen on April 23, 2002 at 08:12.]
 

jlandgr

Smack-Fu Master, in training
56
Originally posted by Larry Loen:
See also: http://www.rsasecurity.com/rsalabs/faq/3-2-2.html for a claim that a machine exists to crack DES in only about a day. I had not seen such a claim before. It uses brute force, apparently.
Hi, it exists, and was sponsored by the Electronic Frontier Foundation. It was used in DES projects done by distributed.net in 1999 and it did contribute immensely to the cracking of the key in a matter of two or three days IIRC.
Details about the machine were published in book form and on the internet, see this page
Jerome
 
H@: You're confusing the nature of the problem with the nature of the solution. A brute force crack simply says try all the keys to see which one works. It says nothing about order, sequentialality, or anything else. The fact that the WE, as humans, solve the problem by trying one key at a time until we find the answer doesnt make the problem itself sequential in nature, it just makes our solution sequential. Current hardware has the same restrictions we do, it can test only one key at a time (altho DNA or quantum computing may actually allow for many keys to be tested concurrently). But that still doesnt mean the problem itself is sequential, just the solutions we use. I realize I'm splitting hairs here, but its important because there's a difference between truely sequntial problems and what you describe. In a truely sequential problem, each step depends on the results from the previous step, which in general is a bad quality for a DC project, as you may not know the results of the previous step for quite a while.


As for the other stuff, yes, DES has some known vulnerability which can allow it to be cracked in a matter of hours or days. I forget the specifics, but I have a friend who works for an network security firm, and I remember discussing this. This is at least partyly why people use triple-DES encryption on things, IIRC correctly that processes greatly reduces the exposure to the vulnerability. Problems like this are the reason so many people are studying crytography right now. A basic brute froce attack in which you try every possible key may take years when a more intelligent attack will succeed in just days. And making an encryption scheme that isnt open to any such attacks is quite challenging.
 
I realize I'm splitting hairs here

Yes and no. We're starting to go past more conventional questions of "shared nothing" versus "shared memory" computing and into computability theory itself.

Some problems, like "optimize the route a traveling salesman should take" would parallelize very well because the obvious algorithm is non-deterministic ("non-polynomial time"). The obvious form of algorithms like that tend to begin "try all possible routes and pick the best." Other well-known problems run in polynomial time. For many polynomial cases, there is something that usually looks more sequential, one way or another, but still permits a certain amount of parallel work. The matrix multiply is a good example.

We can do many of both in parallel, but the nature of the solutions and the solution space is very different.

As a footnote, the academically interesting Ackerman's function looks to me like an exponential cost algorithm ("non-polynomial"), but it is unparallelizable due to its dependency chain. So, not all non-polynomial time algorithms are parallelizable and certainly there are polynomial time algorithms which have no known or at least no easy parallelizability. For instance, an ordinary pseudo-random number generator of the form: next = current*a + b mod M where a, b, and M are constants, would not ordinarily be paralleized, though with work, a certain amount of parallelization is likely, I suppose. A better example, perhaps, would be the various signature algorithms like SHA-1, which is difficult by its very nature to parallelize. Yet, it is clearly polynomial time.

On the whole, I'd expect many non-polynomial time algorithms to parallelize all too well (that is, their solution space explodes, permitting the work to be divided up as it grows like breeding bacteria -- the issue will turn out to be finding a heuristic to stop the explosion). Conversely, while more often tractable in terms of total compute time, at least some polynomial time algorithms will probably often require significant effort to break into useful parallel chunks.
 

et82

Wise, Aged Ars Veteran
154
Basically any simulation of dynamic physical system will never be DC-able. Although they have all many nodes which have to be computed in parrallel, they all require a great deal of cummunication between the nodes.
Best examples for this kind of physical system is weather simulation, Computational Fluid Dynamics, Stress Analysis, etc...

However what is in my opinion scary for the DC-community is that CGI rendering is perfectly DC-able, especially when large bandwiths become more commonplace. I already see Hollywood making bogus DC-projects in life sciences, and using them for cheaply rendering the CGI of the newest blockbuster...
 

dio82

Ars Legatus Legionis
10,407
Subscriptor
I just (OK it became a monster post) want to add this to et's post:

In physical simulations you usually try to solve problems using the Finite Elements Analysis method. Here one "chops" up the domain for which one tries to find a solution (e.g. earth atmosphere for weather) into several hundred thousand to million nodes (actually control volumes).

For each node one then setups the mathematical dependancies which describe the relationships of the variables with each other. One should note that these dependancies only purely describe what crosses the boundaries of the node in which quantities.
The actual condition inside the node is partially a byproduct of the calculations and partially must be interpolated from the calculated information of what crosses the boundaries (This step is usually done in post processing and is calculated in realtime depending on what you want to visualize).

One usually has something like 12-40 simultaneous partial differential equations per node (at least in CFD which is my specialization) which depend upon the information which is given to them from the surrounding nodes (4-12 usually), which depend themselves each on 12-40 simultaneous partial differential equations, which depend upon the information of 4-12 different nodes....
I think you get the idea :)

It then all boils down to an extremely complex web of several tens of millions of partial differential equations which have to be solved simultaneously.
To make things more complicated, the structure of the nodes adapts itself during runtime to the situation in order to build a finer mesh in critical areas, or to reduce the number of nodes in non critical areas...

The problems with parallel processing are quite evident now. In order to do parallel processing the "bonding" that connects the equations has to be broken up. This is the real crunch point!

As you all should know from your maths lessons in school, if you have eg. 5 equations and 5 unknowns, you cannot simply take 2 equations and calculate from these 2 the actual solution of unknown 1 and unknown 2 alone.
BUT this has to be exactly done in order to do parallel processing!!!

This should give one a dimension of what mathematical "deep magic" actually the people do with natural sciences DC projects.
 
Quite right, I was never able to overcome this problem. It gets more horrific when some of the dependencies refer to a predictive model and becomes absolutely impossible when some of the dependencies are actually coming from real time streamed data. So my simulator is going to require an enormous amount of horsepower, much beyond our budget in fact. The alternative approach is to spend lots of time on the mill floor doing real time experiments, despite the costs involved as sponsors more readily cough up for a DOE spanning six months in their production environment rather than helping pay for a supercomputer they don't own.

Hmmm you're doing CFD as well, what are you studying? Perhaps we should be talking, I'm working on gas dispersion in process media.


Originally posted by dio82:
I just (OK it became a monster post) want to add this to _et_'s post:

In physical simulations you usually try to solve problems using the Finite Elements Analysis method. Here one "chops" up the domain for which one tries to find a solution (e.g. earth atmosphere for weather) into several hundred thousand to million nodes (actually control volumes).

For each node one then setups the mathematical dependancies which describe the relationships of the variables with each other. One should note that these dependancies only purely describe what crosses the boundaries of the node in which quantities.
The actual condition inside the node is partially a byproduct of the calculations and partially must be interpolated from the calculated information of what crosses the boundaries (This step is usually done in post processing and is calculated in realtime depending on what you want to visualize).

One usually has something like 12-40 simultaneous partial differential equations per node (at least in CFD which is my specialization) which depend upon the information which is given to them from the surrounding nodes (4-12 usually), which depend themselves each on 12-40 simultaneous partial differential equations, which depend upon the information of 4-12 different nodes....
I think you get the idea :)

It then all boils down to an extremely complex web of several tens of millions of partial differential equations which have to be solved _simultaneously_.
To make things more complicated, the structure of the nodes adapts itself during runtime to the situation in order to build a finer mesh in critical areas, or to reduce the number of nodes in non critical areas...

The problems with parallel processing are quite evident now. In order to do parallel processing the "bonding" that connects the equations has to be broken up. This is the real crunch point!

As you all should know from your maths lessons in school, if you have eg. 5 equations and 5 unknowns, you cannot simply take 2 equations and calculate from these 2 the actual solution of unknown 1 and unknown 2 alone.
BUT this has to be exactly done in order to do parallel processing!!!

This should give one a dimension of what mathematical "deep magic" actually the people do with natural sciences DC projects.
 

dio82

Ars Legatus Legionis
10,407
Subscriptor
I'm a MechEng student @ Imperial College (as my tribus suggests). I am actually going to start after the summer with Finite Elements Analysis, but I have quite a lot of foreknowledge from my father who is a professor in CFD in Germany.

(He is one of the veterans of CFD who has contributed a lot to mesh generation in the stone age of CFD. His specialisation lies in Turbomachinery, but currently he is doing loads of stuff for flow measurement devices)

Back to me, I have a summer job at FLUENT and did some CFD projects for my father, so I actually have more of a "hands on" experience than real theoretical knowledge in terms CFD, but I'm working on that :D .
 

[DSLR] Starfish

Smack-Fu Master, in training
70
Originally posted by jlandgr:
Originally posted by Larry Loen:
See also: http://www.rsasecurity.com/rsalabs/faq/3-2-2.html for a claim that a machine exists to crack DES in only about a day. I had not seen such a claim before. It uses brute force, apparently.
Hi, it exists, and was sponsored by the Electronic Frontier Foundation. It was used in DES projects done by distributed.net in 1999 and it did contribute immensely to the cracking of the key in a matter of two or three days IIRC.
Details about the machine were published in book form and on the internet, see http://www.eff.org/descracker.html
Jerome

Fascinating page Jerome!

Thank you for sharing that link...

http://www.cryptography.com/resources/whitepapers/DES-photos.html

Custom microchips..nice!...makes me wonder again if we could not develop a few add-on cards with DSP chips for Seti or something like that ;) :rolleyes:
 

Hat Monster

Ars Legatus Legionis
47,680
Subscriptor
It would be possible to develop hardware that would crunch SETI@Home. Just a fast FFT cruncher.
We already have it, it's called K7, marketed as Athlon and Duron.
No way is a triple issue out of order FPU going to be the bottleneck.

We could put a card in a PCI slot with just an Athlon's FPU on it. Then what? Drag the machine to a crawl as it rapes the PCI bus trying to get at RAM?

We need a powerful FPU, but also a wide pipe to get the data in. Basically, you need a farming box. Bandwidth is very important. Ever seen how well a i845 doesn't do with SDRAM and a Pentium4? The results ain't pretty. Stick i850 in there with RDRAM and a P4 is competetive (not brilliant) with Athlon for your SETI@Home crunching.

Rumour has it that AMD designed K8, Hammer, with just SETI@Home in mind, since it has stupid bandwidth that scales with the number of CPUs and just as silly FPU power.

If we did reprogram the client (ie. hack it) to utilise a magic card, then the card would be little more than whichever FFT processor you feel like, 32MB of 600MHz DDR and glue logic. The CPU would still have to do the pulse, spike and triplet finding, as well as gaussian curve fitting.

H@
 

[DSLR] Starfish

Smack-Fu Master, in training
70
Originally posted by Hat Monster:
It would be possible to develop hardware that would crunch SETI@Home. Just a fast FFT cruncher.
We already have it, it's called K7, marketed as Athlon and Duron.
No way is a triple issue out of order FPU going to be the bottleneck.

I really like the way you put that, really! ;)

Originally posted by Hat Monster:
We could put a card in a PCI slot with just an Athlon's FPU on it. Then what? Drag the machine to a crawl as it rapes the PCI bus trying to get at RAM?

We need a powerful FPU, but also a wide pipe to get the data in. Basically, you need a farming box. Bandwidth is very important. Ever seen how well a i845 doesn't do with SDRAM and a Pentium4? The results ain't pretty. Stick i850 in there with RDRAM and a P4 is competetive (not brilliant) with Athlon for your SETI@Home crunching.

Very true, but I still like that 'Deep Crack idea. I have to admit though that my previous post was more or less intended with a ;)

When you mentioned 'Bandwidth is very important' I instantly thought 'AMD Hammer + HyperTransport' ...that makes your next line very interesting:

Originally posted by Hat Monster:
Rumour has it that AMD designed K8, Hammer, with just SETI@Home in mind, since it has stupid bandwidth that scales with the number of CPUs and just as silly FPU power.

I didn't hear about that rumour before though! ...perhaps you've got some linkage? :)

I do know that if K8 actually does what AMD says it does ( :eek: :eek: ) it will be ...something else! I am very curious about what's going to happen with the market early next year! :)


Originally posted by Hat Monster:
If we did reprogram the client (ie. hack it) to utilise a magic card, then the card would be little more than whichever FFT processor you feel like, 32MB of 600MHz DDR and glue logic. The CPU would still have to do the pulse, spike and triplet finding, as well as gaussian curve fitting.

H@

Sometimes I wish I knew more about actually designing custom chip circuits... not because I want to hack a Seti client or something like that, but I simply like 'simple' circuits that are designed to execute a special operation very fast..

Maybe I should dive more into that area after I finishing my current study. :cool: :D
 
CPUs have gotten so fast, custom hardware (that isn't onchip) is having a hard time winning the day.

To make some sort of external crack work, you'd have to have a specialty chip that did a lot of work because it will take hundreds of cycles to feed it the data.

However, that begins to argue for more specialization than I know to be practical for most DC. There is or was some "silicon compiler" work going on somewhere in the world, but I hadn't heard it competitive with 50 dollar (250 packaged) Morgan solutions for DC problems. At least not on our budgets.

For something relatively simple and parallelizable like crypto, it can work (e.g. multiple parallel trials or even multiple serial trials), but you really have to think hard about the chip doing a lot of stuff for each time it communicates with the microcontroller or else it just don't pay.

For simple functions that can be handled with reasonable-sized table lookups, you can just forget it.
 
Status
Not open for further replies.