How come Z-Modem is faster than X-Modem?

How come Z-Modem is faster than X-Modem?

Post by Abu Waw » Wed, 20 Mar 1996 04:00:00



I have the specs for the X-modem protocol and I see that it doesn't
add much overhead, just 4 bytes per 128 byte packet. So how come
Z-modem is so much faster? (Unfortunately, I haven't found the specs
for Z-Modem yet.) Does it do compression? Thanks,

Abu Wawda

 
 
 

How come Z-Modem is faster than X-Modem?

Post by Patrick Vestje » Fri, 22 Mar 1996 04:00:00


: I have the specs for the X-modem protocol and I see that it doesn't
: add much overhead, just 4 bytes per 128 byte packet. So how come
: Z-modem is so much faster? (Unfortunately, I haven't found the specs
: for Z-Modem yet.) Does it do compression? Thanks,

As far as I know Zmodem is a streaming protocol while Xmodem is not.
This means that when using Xmodem the sender requires an acknowledgement
from the receiver after each block. In the mean time it just waits and
that costs a lot of time.

Zmodem does not require an acknowledgement after each block. I think it
only sends one if an exception occurred. See the sender just keeps on
sending and sending and sending ...

Regards, Patrick.

 
 
 

How come Z-Modem is faster than X-Modem?

Post by Geoffrey Wel » Wed, 27 Mar 1996 04:00:00



>I have the specs for the X-modem protocol and I see that it doesn't
>add much overhead, just 4 bytes per 128 byte packet. So how come
>Z-modem is so much faster? (Unfortunately, I haven't found the specs
>for Z-Modem yet.) Does it do compression? Thanks,

You're forgetting something very important that XMODEM adds: silence.  After a
packet is transmitted, XMODEM stops dead in its tracks until it gets a reply
from the other end.  When modems were 300 bps and it took a few seconds to
send a single packet, the fraction of a second pause between packets didn't
seem like much of a loss.  With today's modems, the pause takes longer than
the data transmission, resulting in more time wasted than used.

ZMODEM, in its most common application, never stops sending.

Oh, and yes... _full_ ZMODEM implementations include data compression, but
with data compression built in to any decent modem these days, that's not very
important.

--
            Geoffrey Welsh, Developer, InSystems Technologies Inc.


  Capitalism is a cold-hearted system which guards the interests of whoever's
  at the top, yet hypocritically claims that it offers everyone a fair shot.
              So is every other system ever put in place by man.

 
 
 

How come Z-Modem is faster than X-Modem?

Post by Stephen M. Du » Wed, 27 Mar 1996 04:00:00


$: I have the specs for the X-modem protocol and I see that it doesn't
$: add much overhead, just 4 bytes per 128 byte packet. So how come
$: Z-modem is so much faster? (Unfortunately, I haven't found the specs
$: for Z-Modem yet.) Does it do compression? Thanks,
$
$As far as I know Zmodem is a streaming protocol while Xmodem is not.

   Correct.

$This means that when using Xmodem the sender requires an acknowledgement
$from the receiver after each block. In the mean time it just waits and
$that costs a lot of time.

   This is particularly true in the case of a high-latency connection,
such as when an error correction protocol is in use.  LAP-M and MNP
both cut up the data flow into packets, and until the receiving modem
has received and verified an entire packet, it doesn't start sending
that data to the computer.  The computer, in turn, can't verify
the contents of the Xmodem packet until it's all been received,
and so there are additional delays present.

$Zmodem does not require an acknowledgement after each block. I think it
$only sends one if an exception occurred. See the sender just keeps on
$sending and sending and sending ...

   It can run in streaming mode or in sliding window mode, in which
there's an outstanding window of some size and an ack must be sent
at some point during reception of each window size.  Assuming that
the window size is high enough that the acks get back in time,
the sliding window mode will effectively stream anyway.
--

----------------------------------------------------------------------------
Stephen M. Dunn, CNE, ACE, Sr. Systems Analyst, United System Solutions Inc.
104 Carnforth Road, Toronto, ON, Canada M4A 2K7          (416) 750-7946 x251

 
 
 

How come Z-Modem is faster than X-Modem?

Post by br.. » Wed, 27 Mar 1996 04:00:00



> Oh, and yes... _full_ ZMODEM implementations include data compression, but
> with data compression built in to any decent modem these days, that's not
> very important.

Relating to the subject of data compression inside a file transfer
protocol, I have a question that I wonder if anyone has ever done
the tests needed to come up with a definitive answer.

Given a pair of modems that use a decent-sized V.42bis dictionary,
using the common file transfer / data communications protocols (ZMODEM,
Kermit, SLIP, PPP), can you achieve faster overall throughput by turning
on compression in the protocol, or by turning it off and allowing the
modem to do the compression by itself?  Or does it matter much?  Assume
that DTE speed is much greater than connect speed so that you are not DTE
speed limited.  For the protocols that allow bidirectional traffic (SLIP
and PPP), you should probably also limit the traffic to primarily one-way,
with the return traffic being the minimum necessary to maintain the
traffic flow.  Also, the size of the V.42bis dictionary needed to be
"decent" is likely to be another parameter in the equation, as is the
type of data being send by the protocol (some data being more compressable
than others).

The point of the question is that, unlike compression algorithms such as
the LZ algorithm used by GIF and ZIP, most file transfer and data comm
protocols do compression by fairly simple "repeated byte elimination",
that is, if you have a series of repeated bytes the algorithm will send
these as something like:

        <REPEAT-INDICATOR> <REPEATED-BYTE> <REPEAT-COUNT>

(typically 3 bytes), rather than as, for example, the single token that
represents a string of bytes used by more sophisticated algorithms.  Even
if your file is fairly compressable using repeated byte elimination, you
could find that the compression algorithm tends to defeat the dictionary
used by LZ and V.42bis if there are a number of different combinations of
<REPEATED-BYTE> and <REPEAT-COUNT> such that they tend to fill up the
dictionary and crowd out potentially more useful strings.  (Of course
this is likely to require somewhat pathological data :->).  Obviously
you can also run into problems if the data contains a lot of the byte
values used for the <REPEAT-INDICATOR> byte, so that you need to insert
some kind of escape to change the normal meaning of that value, but let's
assume that you're not sending random or pre-compressed data -- ie, that
the data is text or executable or "normal" data files rather than ZIP or
GIF files.  In addition, the types of compression achieved by repeated-
byte elimination are likely to be similar in their effect to what can be
achieved by V.42bis, so that the usefulness of using both is not obvious.

My _guess_ (and that's all that it is at this point) is that, assuming
that you are not DTE-limited in some way, most of the time you'll find
that it makes little or no detectable difference whether the DTE stream
is compressed or not if the compression uses one of these simple schemes
(formats such as ZIP _could_ achieve higher compression if they use a
large enough dictionary).  But has anyone actually run any tests on this?

Bruce C. Wright

 
 
 

How come Z-Modem is faster than X-Modem?

Post by Christian Weisgerb » Wed, 03 Apr 1996 04:00:00



Quote:>    [ ZModem ] can run in streaming mode or in sliding window mode, in which
> there's an outstanding window of some size and an ack must be sent
> at some point during reception of each window size.

ZModem *can* also run in stop-and-go mode. Of course, this is only
useful in pathological environments.

$ sz -L
--

  See another pointless homepage at <URL:http://home.pages.de/~naddy/>.
        -- currently reading: Greg Egan, Our Lady of Chernobyl --

 
 
 

1. AM Radio coming through my modem

I live very close to a 50,000 watt radio antenna. My modem is picking up
the radio signals, which really disrupts my connect speeds. I have a
Wisecom 56K flex internal voice/fax. Does anyone know how to fix this
major headache? Please help!

Paul

2. copy constructor???

3. Z-Modem, Y-Modem Under the SunOS

4. anyone hording eprom updates for amigas?

5. Console Router X-Modem

6. Ciscovision comments requested

7. TFTP and X-Modem Problem

8. Scaling printer output

9. 2900 x-modem bin AND HTML download

10. ^Z when using X-modem in Hyperterminal

11. C-/Pascal-Source of the X-Modem CRC protocol

12. Couriers to allow x-modem upgrades?

13. (Q) Motorola Power modem comes with only PC Fax modem s/w?