Thread: Re: Libraw1394 question
Brought to you by:
aeb,
bencollins
From: Olivier D. <dai...@el...> - 2000-05-09 20:33:02
|
Hi Ashok, I managed to exchange raw data between 2 computers by using an FCP-like method and libraw1394. Mainly, I copied FCP code and extended it to allow data being transferred by chunks of 2k (instead of 512 bytes with bare FCP code). This was pretty easy. Problem is: there is a long delay between every data transfer and even with fast machines (Pentium III 450MHz) and I can't manage to get data transferred faster than 2.5 Mbytes/sec. By using Frank Bonin's implementation of IP-over-1394 (which use async transactions), I can ftp-transfer as fast as 15Mbytes/sec with slow machines (pentium 200MMX) so I guess I should be able to do as fast as him... I'm working on a way to speed-up transfer because I need at least 12Mbytes/sec. I think the problem is that the code waits for an acknowledge before sending another packet. If you have any other suggestions, please help. Olivier Ashok Natarajan wrote: > Hi Olivier, > I was also trying to implement the asynchronous data transfer between > linux pc's through the 1394 interface.Then i got busy in something else > and didnt have time to work on this.From the postings i came to know that > u r trying to develop and application to perform the asynchronous > tarnasactions.I'll be willing to assist u in testing of u'r code.Do u have > any code written at all?. > > Ashok. > > > _______________________________________________________________________ > / Ashok Natarajan | | \ > | Research Assistant | __ __ | | > | Dept. of ECE | / \/ \ | Some goals are so | > | Univ. of Tennessee | | | | worthy,its glorious | > |___________________________| \ / | even to fail. | > | Ph.no: | \/ | | > | (931)-393-7107 (home) | | | > | (931)-393-7366 (work) | ana...@ut... | | > ___________________________|___________________|_______________________/ -- Olivier Daigle Projet Harfang (514) 396-8800 ext.7699 |
From: Mark K. <mk...@co...> - 2000-05-09 21:38:51
|
Oliver, I'm not clear that the acknowledge packet is the issue because it is hardware generated and returns quite quickly. Generally this doesn't take much extra time, although on an un-optimized bus with the gap count set to 63 it is measurable. We've done some similar work under WinDoze - I don't know how closely it tracks here, but in that environment we were seeing interrupt latencies driving the return of response packets in the order of 1mS, implying the ability to do about only about 1000 I/O's per second between 2 moderately fast PCs. (333/425MHz) Assuming you're seeing something similar under Linux, then I'd expect that you'd get a throughput of about 1000 packets/second * 2K bytes/packet * 8 bits/byte = 16Mb/S, or 2MB/S, roughly similar to the sorts of numbers you seem to be seeing. You could check that this is driven mostly by system latencies by changing you packet sizes to say 1K and 512 bytes and see if the throughput changes roughly linearly. What's the solution? The applications that are driving this pipe need to be able to make multiple requests of the 1394 bus such that the overall system latency gets covered up and data is moving all the time. When you do that you start to see the performance go up significantly. Certainly you'll need a driver stack that supports this cleanly. This sort of issue isn't likely to rear it's ugly head for those applications transferring real-time video data from consumer level camcorders. It is, however, likely to be a big problem for high performance disk drives talking SPB-2. With best regards, Mark -----Original Message----- From: Olivier Daigle [mailto:dai...@el...] Sent: Tuesday, May 09, 2000 1:33 PM To: Ashok Natarajan Cc: Linux1394-devel Subject: Re: Libraw1394 question Hi Ashok, I managed to exchange raw data between 2 computers by using an FCP-like method and libraw1394. Mainly, I copied FCP code and extended it to allow data being transferred by chunks of 2k (instead of 512 bytes with bare FCP code). This was pretty easy. Problem is: there is a long delay between every data transfer and even with fast machines (Pentium III 450MHz) and I can't manage to get data transferred faster than 2.5 Mbytes/sec. By using Frank Bonin's implementation of IP-over-1394 (which use async transactions), I can ftp-transfer as fast as 15Mbytes/sec with slow machines (pentium 200MMX) so I guess I should be able to do as fast as him... I'm working on a way to speed-up transfer because I need at least 12Mbytes/sec. I think the problem is that the code waits for an acknowledge before sending another packet. If you have any other suggestions, please help. Olivier Ashok Natarajan wrote: Hi Olivier, I was also trying to implement the asynchronous data transfer between linux pc's through the 1394 interface.Then i got busy in something else and didnt have time to work on this.From the postings i came to know that u r trying to develop and application to perform the asynchronous tarnasactions.I'll be willing to assist u in testing of u'r code.Do u have any code written at all?. Ashok. _______________________________________________________________________ / Ashok Natarajan | | \ | Research Assistant | __ __ | | | Dept. of ECE | / \/ \ | Some goals are so | | Univ. of Tennessee | | | | worthy,its glorious | |___________________________| \ / | even to fail. | | Ph.no: | \/ | | | (931)-393-7107 (home) | | | | (931)-393-7366 (work) | ana...@ut... | | ___________________________|___________________|_______________________/ -- Olivier Daigle Projet Harfang (514) 396-8800 ext.7699 |
From: Mark K. <mk...@co...> - 2000-05-11 13:26:16
|
Sebastien, Without waiting for the ACK, or without waiting for the response packet? Mark -----Original Message----- From: Sebastien Rougeaux [mailto:Seb...@sy...] Sent: Wednesday, May 10, 2000 7:19 PM To: dai...@el... Cc: ana...@ut...; lin...@li... Subject: Re: Libraw1394 question >>>>> "Olivier" == Olivier Daigle <dai...@el...> writes: Olivier> --------------80790F6F4A9A7A46D27C5FE8 Content-Type: text/plain; Olivier> charset=us-ascii Content-Transfer-Encoding: 7bit Olivier> Hi Ashok, I managed to exchange raw data between 2 computers by using Olivier> an FCP-like method and libraw1394. Mainly, I copied FCP code and Olivier> extended it to allow data being transferred by chunks of 2k (instead Olivier> of 512 bytes with bare FCP code). This was pretty easy. Problem is: Olivier> there is a long delay between every data transfer and even with fast Olivier> machines (Pentium III 450MHz) and I can't manage to get data Olivier> transferred faster than 2.5 Mbytes/sec. By using Frank Bonin's Olivier> implementation of IP-over-1394 (which use async transactions), I can Olivier> ftp-transfer as fast as 15Mbytes/sec with slow machines (pentium Olivier> 200MMX) so I guess I should be able to do as fast as him... Olivier> I'm working on a way to speed-up transfer because I need at least Olivier> 12Mbytes/sec. I think the problem is that the code waits for an Olivier> acknowledge before sending another packet. If you have any other Olivier> suggestions, please help. The OHCI driver has been designed to send multiple packets without waiting for the ack (currently the max is set to 32)... However I think it never happens because of the internal mechanism of the subsystem/libraw. You probably should ask Andreas Bombe about that. -- Sebastien Rougeaux RSISE, The Australian National University _______________________________________________ mailing list lin...@li... http://lists.sourceforge.net/mailman/listinfo/linux1394-devel |
From: Sebastien R. <Seb...@sy...> - 2000-05-12 09:21:55
|
>>>>> "Mark" == Mark Knecht <mk...@co...> writes: Mark> Sebastien, Without waiting for the ACK, or without waiting for the Mark> response packet? Mark The ohci driver just queues the outgoing packets that it receives from the subsystem into a fifo, and returns immediately after that, unless the fifo is full, in which case it is put to sleep and it should output a debug message (which I have never seen so far). No waiting for ack nor response packet (it is later signaled to the subsystem upon reception). -- Sebastien Rougeaux RSISE, The Australian National University |
From: Sebastien R. <Seb...@sy...> - 2000-05-11 02:17:44
|
>>>>> "Olivier" == Olivier Daigle <dai...@el...> writes: Olivier> --------------80790F6F4A9A7A46D27C5FE8 Content-Type: text/plain; Olivier> charset=us-ascii Content-Transfer-Encoding: 7bit Olivier> Hi Ashok, I managed to exchange raw data between 2 computers by using Olivier> an FCP-like method and libraw1394. Mainly, I copied FCP code and Olivier> extended it to allow data being transferred by chunks of 2k (instead Olivier> of 512 bytes with bare FCP code). This was pretty easy. Problem is: Olivier> there is a long delay between every data transfer and even with fast Olivier> machines (Pentium III 450MHz) and I can't manage to get data Olivier> transferred faster than 2.5 Mbytes/sec. By using Frank Bonin's Olivier> implementation of IP-over-1394 (which use async transactions), I can Olivier> ftp-transfer as fast as 15Mbytes/sec with slow machines (pentium Olivier> 200MMX) so I guess I should be able to do as fast as him... Olivier> I'm working on a way to speed-up transfer because I need at least Olivier> 12Mbytes/sec. I think the problem is that the code waits for an Olivier> acknowledge before sending another packet. If you have any other Olivier> suggestions, please help. The OHCI driver has been designed to send multiple packets without waiting for the ack (currently the max is set to 32)... However I think it never happens because of the internal mechanism of the subsystem/libraw. You probably should ask Andreas Bombe about that. -- Sebastien Rougeaux RSISE, The Australian National University |
From: Andreas B. <and...@mu...> - 2000-05-12 23:35:24
|
On Tue, May 09, 2000 at 04:32:37PM -0400, Olivier Daigle wrote: > Hi Ashok, > I managed to exchange raw data between 2 computers by using an FCP-like > method and libraw1394. Mainly, I copied FCP code and extended it to allow data > being transferred by chunks of 2k (instead of 512 bytes with bare FCP code). > This was pretty easy. Problem is: there is a long delay between every data > transfer and even with fast machines (Pentium III 450MHz) and I can't manage to > get data transferred faster than 2.5 Mbytes/sec. By using Frank Bonin's > implementation of IP-over-1394 (which use async transactions), I can > ftp-transfer as fast as 15Mbytes/sec with slow machines (pentium 200MMX) so I > guess I should be able to do as fast as him... Depends on how you implemented the transfer protocol. FCP is more expensive since request and response are each full 1394 write transactions consisting of request and response packets themselves, theoretically this makes FCP take up twice as much packets as low level transactions. Have you tried to minimize the requests? Don't require responses for every FCP write but only for every dozen or so (which contains the individual responses all at once) and a response on timeout (in case not enough packets are around). This should enhance throughput (but might decrease responsiveness a little since responses might be delayed). Additionally, at a lower level, you can also send out multiple packets without waiting for the hardware to actually do it. Use raw1394_start_write() without raw1394_loop_iterate() after each packet. -- Andreas E. Bombe <and...@mu...> DSA key 0x04880A44 http://home.pages.de/~andreas.bombe/ http://linux1394.sourceforge.net/ |