Go to advanced search

by Bakul Shah
Fri Jun 28, 2013 12:28 am
Forum: Plan 9
Topic: New plan9 image
Replies: 0
Views: 12886

New plan9 image

Richard has put a new plan9 image in http://plan9.bell-labs.com/sources/contrib/miller/9pi.img.gz . Not much is new but it should work with model-A RPi now + it is updated for 21 bit runes. To keep your sources uptodate, you can use the pull command. To avoid downloading x86 bits (about 235MB), repl...
by Bakul Shah
Wed Jun 26, 2013 10:35 am
Forum: General discussion
Topic: New Threads and Processes
Replies: 5
Views: 1202

Re: New Threads and Processes

Hi, I have tried and tested the three seperate binaries with much joy. Now I want to tie them together. From my research into threads and processes I'm pretty sure I want to launch the two binaries (camera and 3G) as processes and NOT threads. This being due to threads operating in the same address...
by Bakul Shah
Wed Jun 12, 2013 5:47 pm
Forum: Other programming languages
Topic: Dyalog APL available for the Pi
Replies: 21
Views: 10308

Re: Dyalog APL available for the Pi

APL's reduce is a "right fold" (in functional programming terms). That is, f/V == v0 f (v1 f (v2 ...)), right? So then the Nth terms of f\, which is just f/ on the first N vector entries, will be computed differently from the N+1th term. Most of my recent experience with k, which defines f/ to be a ...
by Bakul Shah
Wed Jun 12, 2013 12:36 am
Forum: Other programming languages
Topic: Dyalog APL available for the Pi
Replies: 21
Views: 10308

Re: Dyalog APL available for the Pi

Just kicking tires.... x←⍳10000000 ]cputime x+x * Benchmarking "x+x" * Command Execution Failed: WS FULL ⎕wa 66275016 Clearly 66MB is not enough to add two 10M entry integer vectors. Is there a way to allocate more memory? The following seems to have an O(n^2) behavior. But when + is used instead of...
by Bakul Shah
Tue Jun 11, 2013 8:45 pm
Forum: Other programming languages
Topic: Dyalog APL available for the Pi
Replies: 21
Views: 10308

Re: Dyalog APL available for the Pi

Thanks very much, Jason & Dyalog! Further notes: In Terminal preferences->settings->keyboard deselect "Use Option as Metakey". If you use Xquartz, in preferences->Input deselect "Option Keys sent Alt_L and Alt_R". Without this change you won't be able to type option+i for iota etc. ⌘; is a handy sho...
by Bakul Shah
Tue Jun 11, 2013 2:36 am
Forum: Other programming languages
Topic: Dyalog APL available for the Pi
Replies: 21
Views: 10308

Re: Dyalog APL available for the Pi

OK, Problem solved! I did this: cat >> ~/.Xresource <<'EOF' UXTerm*faceFont: APL386 Unicode EOF xrdb -merge ~/.Xresources So everything works locally using uxterm . lxterminal still misbehaves but I don't care about it. xterm is not in the default Raspbian distro so you'd have to sudo apt-get xterm ...
by Bakul Shah
Mon Jun 10, 2013 10:24 pm
Forum: Other programming languages
Topic: Dyalog APL available for the Pi
Replies: 21
Views: 10308

Re: Dyalog APL available for the Pi

[Edit] I connected a display to the RPi and exactly followed the instructions in the dyalog apl for RPi users and selected the right font from the lxterminal's edit->preferences menu etc. but instead of special chars I see a diamond with a ? in it. If I manually start uxterm and cat aplkeys/xterm I...
by Bakul Shah
Sat Jun 08, 2013 9:21 pm
Forum: Other programming languages
Topic: Dyalog APL available for the Pi
Replies: 21
Views: 10308

Re: Dyalog APL available for the Pi

Good to see this! But I haven't had a chance to play with this. I briefly tried logging in from a mac (no display on the RPi) but couldn't figure out how to input APL chars. Using KAPL font with xterm on the mac at least displays APL chars but not with APL385. [Edit] I connected a display to the RPi...
by Bakul Shah
Wed May 29, 2013 10:50 pm
Forum: General discussion
Topic: Help!!!
Replies: 24
Views: 5086

Re: Help!!!

Talk to her and find out why she says you don't need one. Listen to her and try to understand her reasoning (I suspect she has some valid concerns like not doing your homework or chores etc.). Then figure out how to allay her concerns. Explain how having it would benefit you. Get her excited about a...
by Bakul Shah
Sun May 26, 2013 8:27 pm
Forum: General discussion
Topic: Something the Pi is not good at - calculating Pi
Replies: 175
Views: 32865

Re: Something the Pi is not good at - calculating Pi

I just found this amazing statement from Alex Yee the current holder of the record for caculating the most digits of pi: 2 cents from the current world record holder for the most digits of Pi: Computing many digits of Pi is a communication-bound task rather than a computation-bound task. So I highl...
by Bakul Shah
Thu May 23, 2013 9:42 pm
Forum: General discussion
Topic: Something the Pi is not good at - calculating Pi
Replies: 175
Views: 32865

Re: Something the Pi is not good at - calculating Pi

This trivial: if you have N processors, just split the series in N subseries and compute each one independently and finally add them up and then return the reciprocal. Clearly the deepest terms are the hardest to calculate. The question is how much of the work done in parallel on earlier terms is n...
by Bakul Shah
Thu May 23, 2013 8:46 pm
Forum: General discussion
Topic: Maker Fairey Tales - NOOBS and Pidora and Wayland, Oh My!
Replies: 53
Views: 16786

Re: Maker Fairey Tales - NOOBS and Pidora and Wayland, Oh My

So, what was your problem, Bunky? I too have no idea who Bunky is or what it is in refernce to. Amazing -- for some reason there's no reference to it on Wikipedia. There's an old [USA and maybe elsewhere] comedy routine entitled "What's the matter, Bunky?" where an old codger is trying to console h...
by Bakul Shah
Thu May 23, 2013 8:27 am
Forum: General discussion
Topic: Something the Pi is not good at - calculating Pi
Replies: 175
Views: 32865

Re: Something the Pi is not good at - calculating Pi

Let's consider a simpler formula to see the problem. f(k) = k! and we want sum f(k) for k in [0..n) We can split that into two parallel threads for sum f(k), k in [0..m) and sum f(k), k in [m+1..n) the results of which are to be added. Some time you have to transform the problem. For instance: let ...
by Bakul Shah
Thu May 23, 2013 1:27 am
Forum: General discussion
Topic: Something the Pi is not good at - calculating Pi
Replies: 175
Views: 32865

Re: Something the Pi is not good at - calculating Pi

1) Memory access speed is the bottle neck for this calculation. At least on the Pi. Note: this is just my guess. I am too lazy to do a proper analysis or measure actual memory IO! 2) The terms can be grouped into batches and batches can be calculated in parallel. Putting those two facts together I ...
by Bakul Shah
Thu May 23, 2013 1:02 am
Forum: General discussion
Topic: Something the Pi is not good at - calculating Pi
Replies: 175
Views: 32865

Re: Something the Pi is not good at - calculating Pi

As Jim says, such series computation can be parallelized. Not convinced. Certainly, gmp-chudnovsky.c exploits no parallelism at all. (Ignoring superscalar pipelining determined in hardware.) This trivial: if you have N processors, just split the series in N subseries and compute each one independen...
by Bakul Shah
Wed May 22, 2013 11:36 pm
Forum: General discussion
Topic: Something the Pi is not good at - calculating Pi
Replies: 175
Views: 32865

Re: Something the Pi is not good at - calculating Pi

Looking at the ratios of the clock frequencies we see that the ARMs are not doing very well clock for clock against the Intel/AMD. This may be because the memory interface on the Raspi has a much lower bandwidth than what the AMD/Intel 64 bit machines have and this algorithm seems memory bound. Eac...
by Bakul Shah
Tue May 21, 2013 11:14 am
Forum: General discussion
Topic: Something the Pi is not good at - calculating Pi
Replies: 175
Views: 32865

Re: Something the Pi is not good at - calculating Pi

It has been suggested that advantage can be taken of the GPU even without knowing about its internals. That is by using the OpenGL ES API. This may well be true, but then in my quick Googling around of have not seen anyone anywhere doing that for any platform with OpenGL. ES or otherwise. I would s...
by Bakul Shah
Tue May 21, 2013 10:08 am
Forum: General discussion
Topic: Something the Pi is not good at - calculating Pi
Replies: 175
Views: 32865

Re: Something the Pi is not good at - calculating Pi

The Pi digit problem may not be amenable to a GPU solution on the Pi board compared with the ARM CPU and FPU (that people keep conveniently forgetting about), and while I may not have time to determine it, there are people who can, and I'm going to enlist their help. More about that in the next pos...
by Bakul Shah
Tue May 21, 2013 9:52 am
Forum: General discussion
Topic: Something the Pi is not good at - calculating Pi
Replies: 175
Views: 32865

Re: Something the Pi is not good at - calculating Pi

Bakul, A nice summary but I am slightly puzzled by one point. We have already established the title of this discussion thread is false. Probably a good thing in hindsight : - ) Do you mean that the Pi is a good platform for calculating pi? I would say that the Pi is an acceptable platform for the j...
by Bakul Shah
Mon May 20, 2013 10:38 pm
Forum: General discussion
Topic: Something the Pi is not good at - calculating Pi
Replies: 175
Views: 32865

Re: Something the Pi is not good at - calculating Pi

There are several intermingled threads. We have already established the title of this discussion thread is false. Probably a good thing in hindsight : - ) There are several algorithms that are much faster at computing pi (AGM, Chudnovksy etc.) than the old "schoolboy method". An integral component o...
by Bakul Shah
Sat May 18, 2013 11:33 pm
Forum: Other programming languages
Topic: Flumoxed - C To Pascal code conversion
Replies: 7
Views: 2271

Re: Flumoxed - C To Pascal code conversion

I am guessing either you are running this as a normal user or you didn't open /dev/mem and put the resulting file descriptor in mem_fd. But there is no need for GetMem(). You can even do something like the following if you don't care about wasting an open file descriptor! gpioreg := Fpmmap(Nil, BLOC...
by Bakul Shah
Fri May 17, 2013 9:13 pm
Forum: General discussion
Topic: Something the Pi is not good at - calculating Pi
Replies: 175
Views: 32865

Re: Something the Pi is not good at - calculating Pi

If anyone who can read actually goes and looks at the honorable Ooura-san's source (http://left404.com/misc/files/pi_css5/pi_css5_src.tgz), they will see references to FFT, which a few folks here should recognize as the Fast Fourier Transform. In particular, there is a curious note about "Number of...
by Bakul Shah
Fri May 17, 2013 6:51 am
Forum: General discussion
Topic: Something the Pi is not good at - calculating Pi
Replies: 175
Views: 32865

Re: Something the Pi is not good at - calculating Pi

Takuya Ooura's pi_css5 program on the Raspi computes the first million digits of Pi in under 79 seconds (compared to under 3s on a 3.6Ghz AMD FX). So I'd say the Raspi is plenty fast!

And Jim, AFAIK programs computing first N digits of π don't benefit by using a GPU!
by Bakul Shah
Wed May 01, 2013 6:01 am
Forum: Troubleshooting
Topic: SOLVED overclocking apparently works for RAM and not for CPU
Replies: 6
Views: 1191

Re: overclocking apparently works for RAM and not for CPU

IIRC you have to add

force_turbo=1

to config.txt. Without this it will only ramp up the processor clock as needed.
by Bakul Shah
Mon Apr 29, 2013 9:21 am
Forum: Troubleshooting
Topic: USB redux
Replies: 514
Views: 209171

Re: USB redux

In general moving the FIQ code to the GPU is quite simple but doesn't really get you very much (it's just removing a very small piece of code that probably executes something like 0.01% of the CPU). This is much better; I didn't think it would be quite so simple. Anyway, if you did just that, would...

Go to advanced search