[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: pa_cstruct first cut available



On 10 May 2012, at 16:48, Richard Mortier wrote:

> 
> On 10 May 2012, at 16:42, Anil Madhavapeddy wrote:
> 
>> If noone has any objections, I'll add unit tests for the write path, and 
>> merge this into Mirage in my os-bigarray branch.  I dont think we actually 
>> need bitstring at all anymore.
> 
> sweet :)  none from me!
> 
> by way of a request for status, what are the branches we should currently be 
> tracking for mirage, or just wait until you announce the results of the big 
> split/merge?

I'm working in os-bigarray in my tree, and that's going to touch pretty much 
every file in OS and Net.  So I'm just going to work through it as quickly as 
possible and get it over with. Once that's done, we can benchmark using 
Balraj's TCP tests again, and verify that the write path is up to full speed.

> 
>> Mort: reckon you can easily port the DNS code to this? It should speed up 
>> the responses an awful lot.
> 
> i'll take a look.  and, as i threatened, pyrt too :)

Great, if you want to do this in parallel, you could make avsm/ocaml-dns use 
pa_cstruct. You can get the packets in Bigarray in vanilla UNIX/Lwt via 
Lwt_bytes.recv_msg, which is the same underlying type.  Would be good to run a 
quick perf comparison before/after to make sure it is indeed faster and 
allocates less...

Incidentally, the pa_cstruct design makes it quite easy to eliminate bounds 
checks, by adding an 'attach' operation which verifies the overall bound of a 
buffer, and uses unsafe accesses within the generated code. However, I'll only 
do this if performance becomes an issue, since I prefer no unsafe accesses at 
all.

-anil


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.