Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 29 Oct 2008 15:34:05 +0200
From:      Alexander Motin <mav@FreeBSD.org>
To:        Bartosz Giza <gizmen@blurp.pl>
Cc:        freebsd-net@freebsd.org
Subject:   Re: two NIC on 2 core system (scheduling problem)
Message-ID:  <4908664D.4090900@FreeBSD.org>
In-Reply-To: <200810291337.44899.gizmen@blurp.pl>
References:  <1225203780.00029971.1225190402@10.7.7.3> <200810290953.28237.gizmen@blurp.pl> <49083CBD.1000701@FreeBSD.org> <200810291337.44899.gizmen@blurp.pl>

next in thread | previous in thread | raw e-mail | index | archive | help
Bartosz Giza wrote:
> So now i am lost again. If packet filtering on bge card is counted to irq17: 
> bge0 process so i think it should use more cpu.
> From what you wrote there should be no difference  for me if card use tasq 
> or irq. Those processes do exactly the same thing? If that is true so why 
> there is so much difference in cpu usage:
> 
>   20 root       1 -68    -     0K     8K -      0 161:01 18.75% em0 taskq
>    21 root       1 -68    -     0K     8K WAIT   1 100:10  5.47% irq17: bge0
>    23 root       1 -68    -     0K     8K WAIT   0  75:31  2.98% irq16: fxp1
> 
> If what you wrote is true that overhead of incomming packet on bge0 should 
> be counted to irq17: bge0
> So don't understand why there is so big cpu usage on em0. From what you are 
> saying irq17 and em0 taskq should have similar usage. Even more bge0 passes 
> about two times more traffic  than em0. I simply don't understand this.

> So don't understand why there is so big cpu usage on em0.

Have no idea, there are too much possibilities to answer without
profiling. Different incoming packet rates, different firewall match
patterns in opposite directions, different card's hardware at least. I
have noticed that even different types of em cards may have twice as
different CPU usage due to using different interrupt moderation techniques.

> bge0 passes about two times more traffic  than em0

Incoming or outgoing? Outgoing does not affect time accounting as much
as incoming, because transmit interrupt handler usually does not call
network stack.

-- 
Alexander Motin



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4908664D.4090900>