Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 4 Apr 2007 09:35:46 -0700
From:      Marcel Moolenaar <xcllnt@mac.com>
To:        ticso@cicely.de
Cc:        Bernd Walter <ticso@cicely12.cicely.de>, freebsd-arm@freebsd.org
Subject:   Re: adding 16550 UART to RM9200
Message-ID:  <AF139DFD-8D75-4F18-B574-74B962DD9DFB@mac.com>
In-Reply-To: <20070404140052.GD80382@cicely12.cicely.de>
References:  <20070403154858.GR80382@cicely12.cicely.de> <46135EDC.30700@bulinfo.net> <20070404093651.GY80382@cicely12.cicely.de> <46139CE3.6090806@bulinfo.net> <20070404140052.GD80382@cicely12.cicely.de>

next in thread | previous in thread | raw e-mail | index | archive | help
On Apr 4, 2007, at 7:00 AM, Bernd Walter wrote:

> Not shure about the sio(4) vs. uart(4) performance difference.

I ran some tests (up to 230400bps) and if there's a difference in
performance at all I found it to be in favor of uart(4). I don't
want to claim having done extensive testing and given how marginal
differences are, I also don't want to claim that uart(4) is better
performing. All I say is that claims that sio(4) performs better
than uart(4) are based on ... euh... who knows :-)

In short: I didn't find performance to be a concern.

I still have the following puc(4) & uart(4)  results on a sticky
note (for hysterical raisins :-)

TEST 1: puc(4) performance testing after I rewrote puc(4):
o  compares performance between uart0 & uart1 (determines
    favoritism)
o  compares performance between transmit (DTE) & receive (DCE)

CVS HEAD:
	DTE0:
		6.15 real         0.05 user         4.98 sys
		6.14 real         0.05 user         4.96 sys
		6.16 real         0.04 user         5.01 sys
	DTE1:
		6.14 real         0.02 user         4.99 sys
		6.15 real         0.07 user         4.88 sys
		6.14 real         0.04 user         4.87 sys

	DCE0:
		6.15 real         0.06 user         5.02 sys
		6.15 real         0.05 user         5.00 sys
		6.14 real         0.10 user         4.96 sys
	DCE1:
		6.16 real         0.08 user         5.00 sys
		6.15 real         0.07 user         5.05 sys
		6.14 real         0.07 user         4.96 sys

Perforce uart branch (puc(4) rewrite):
	DTE0:
		6.03 real         0.18 user         3.25 sys
		6.09 real         0.22 user         4.95 sys
		6.17 real         0.24 user         4.74 sys
	DTE1:
		6.02 real         0.16 user         3.33 sys
		6.05 real         0.28 user         4.81 sys
		6.07 real         0.29 user         4.75 sys
	DCE0:
		6.14 real         0.31 user         4.55 sys
		6.22 real         0.36 user         4.62 sys
		6.19 real         0.31 user         4.56 sys
	DCE1:
		6.10 real         0.40 user         4.41 sys
		6.11 real         0.29 user         4.59 sys
		6.14 real         0.33 user         4.52 sys


TEST2: uart(4) performance testing including sio(4) -- I
think it's the serdev I/F ...
o  I can't recall what A and B means, but A was bad :-)
o  HEAD represents CVS current at some time
o  UART represents the Perforce uart branch

KERMIT:
	HEAD:
		cuau0=receive, cuau1=transmit:
		A	00:02:42 - 11016 CPS
		B	00:02:37 - 11361 CPS
		B	00:02:37 - 11360 CPS (sio)
		cuau0=transmit, cuau1=receive:
		A	00:02:42 - 11020 CPS
		B	00:02:37 - 11362 CPS
		B	00:02:37 - 11362 CPS (sio)
	UART:
		cuau0=receive, cuau1=transmit:
		A	00:02:43 - 10963 CPS
		B	00:02:37 - 11363 CPS
		cuau0=transmit, cuau1=receive:
		A	00:02:42 - 11016 CPS
		B	00:02:37 - 11364 CPS

CPS between sio(4) and uart(4) are on par with a small
win for uart(4) after my changes (those are in HEAD now).
I think uart(4) has a slightly bigger interrupt overhead,
so for higher speeds (>230400 or even >460800) this may
kick in.

In your case: uart(4) will do just fine :-)

-- 
Marcel Moolenaar
xcllnt@mac.com





Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?AF139DFD-8D75-4F18-B574-74B962DD9DFB>