Re: Shooting trouble on a PCI bus hang

2011-06-15 Thread Patrick Powell

On 06/14/11 20:52, Ansar Mohammed wrote:

Hello All,
I have a system that is intermitently hanging during the initial PCI bus
scan during boot. I have turned on verbose logging and I cannot break to
debugger as its a hang. Can someone guide me to the relevant code section
where PCI bus enumeration occurs so that I may modify the kernel source to
output even more debug info.

My hang occurs at the end of this partial dmesg output.

Thank you!

pci0:  on pcib0
pci0: domain=0, physical bus=0
found->  vendor=0x100b, dev=0x0028, revid=0x21

domain=0, bus=0, slot=1, func=0
class=06-00-00, hdrtype=0x00, mfdev=1
cmdreg=0x0005, statreg=0x0220, cachelnsz=8 (dwords)
lattimer=0xf8 (7440 ns), mingnt=0x00 (0 ns), maxlat=0x00 (0 ns)
map[10]: type I/O Port, range 32, base 0xac1c, size  2, enabled

found->  vendor=0x100b, dev=0x0030, revid=0x00

domain=0, bus=0, slot=1, func=1
class=03-00-00, hdrtype=0x00, mfdev=0
cmdreg=0x0003, statreg=0x0220, cachelnsz=8 (dwords)
lattimer=0x00 (0 ns), mingnt=0x00 (0 ns), maxlat=0x00 (0 ns)
map[10]: type Memory, range 32, base 0x4100, size 24, enabled
map[14]: type Memory, range 32, base 0x40ffc000, size 14, enabled
map[18]: type Memory, range 32, base 0x40ff8000, size 14, enabled
map[1c]: type Memory, range 32, base 0x40ff4000, size 14, enabled

found->  vendor=0x10ec, dev=0x8139, revid=0x10

domain=0, bus=0, slot=14, func=0
class=02-00-00, hdrtype=0x00, mfdev=0
cmdreg=0x0007, statreg=0x0290, cachelnsz=0 (dwords)
lattimer=0x40 (1920 ns), mingnt=0x20 (8000 ns), maxlat=0x40 (16000 ns)
intpin=a, irq=11
powerspec 2  supports D0 D1 D2 D3  current D0
map[10]: type I/O Port, range 32, base 0xef00, size  8, enabled
map[14]: type Memory, range 32, base 0xeff0, size  8, enabled

$PIR: 0:14 INTA routed to irq 11
found->  vendor=0x1022, dev=0x2090, revid=0x03

domain=0, bus=0, slot=15, func=0
class=06-01-00, hdrtype=0x00, mfdev=1
cmdreg=0x0009, statreg=0x02a0, cachelnsz=8 (dwords)
lattimer=0x40 (1920 ns), mingnt=0x00 (0 ns), maxlat=0x00 (0 ns)
map[10]: type I/O Port, range 32, base 0x6000, size 3, enabled map[14]: type
I/O Port, range 32, base 0x6100, size 8, enabled map[18]: type I/O Port,
range 32, base 0x6200, size 6, enabled map[1c]: type I/O Port, range 32,
base 0, size 5, enabled map[20]: type I/O Port, range 32, base 0x9d00, size
7, enabled map[24]: type I/O Port, range 32, base 0x9c00, size 6, enabled
___
freebsd-hackers@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to "freebsd-hackers-unsubscr...@freebsd.org"

Before you do anything else,  get another set of hardware and try the 
same thing on it.  I had a similar problem that turned out to be a bad 
SATA controller.   It was only by accident that we had two identical 
systems,  one good and one bad.


--
Patrick Powell Astart Technologies
papow...@astart.com1530 Jamacha Road, Suite X,
Network and System San Diego, CA 92019
  Consulting   858-874-6543
Web Site: www.astart.com

___
freebsd-hackers@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to "freebsd-hackers-unsubscr...@freebsd.org"


Why user time of the process depends on machine load?

2011-06-15 Thread Yuri
When I test performance of the code, I always observe dependency of CPU 
user time on the presence of other CPU intense processes.
Same CPU-only deterministic process that on the quiet machine completes 
in 220 user seconds in the presence of, for example, kde rebuild would 
complete in 261, 266 or even 379 user seconds.
I am talking about times shown by time(1), not actual an execution time. 
It's the same time as getrusage(2) returns in ru_utime field.


Why time that process takes in user seconds depends on what other 
processes are running?


FreeBSD-8.2 STABLE on i7 CPU @ 9200 @ 2.67GHz.

Yuri
___
freebsd-hackers@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to "freebsd-hackers-unsubscr...@freebsd.org"


Re: Why user time of the process depends on machine load?

2011-06-15 Thread Dan Nelson
In the last episode (Jun 15), Yuri said:
> When I test performance of the code, I always observe dependency of CPU
> user time on the presence of other CPU intense processes.  Same CPU-only
> deterministic process that on the quiet machine completes in 220 user
> seconds in the presence of, for example, kde rebuild would complete in
> 261, 266 or even 379 user seconds.  I am talking about times shown by
> time(1), not actual an execution time.  It's the same time as getrusage(2)
> returns in ru_utime field.
> 
> Why time that process takes in user seconds depends on what other 
> processes are running?
> 
> FreeBSD-8.2 STABLE on i7 CPU @ 9200 @ 2.67GHz.

Some possible factors:

o Intel Turbo Boost, which raises the clock rate of a single core if the
  other cores are idle.  A single process on an idle system will run faster.

o i7 chips have a shared L3 cache across all cores, so a single process on
  an idle system will tend to have more of its data in cache compared to a
  system with multiple processes, so it spends less time waiting for slower
  physical memory lookups.

o Process accounting isn't exact.  I may be wrong, but I don't think
  timestamps are taken every time a syscall is invoked and returns.  Some
  time marked as "user" may actually be "system" time, in which case you may
  be seeing the effect of contention in the kernel as more processes are
  run.

You may be able to disable Turbo Boot in your BIOS, which you can use to
determine how much of the single-process speedup is due to that.

Unrelated but still interesting note on your particular CPU:
http://www.passmark.com/forum/showthread.php?t=2256

-- 
Dan Nelson
dnel...@allantgroup.com
___
freebsd-hackers@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to "freebsd-hackers-unsubscr...@freebsd.org"


Re: Why user time of the process depends on machine load?

2011-06-15 Thread Artem Belevich
Hi,

On Wed, Jun 15, 2011 at 2:55 PM, Dan Nelson  wrote:
> In the last episode (Jun 15), Yuri said:
>> When I test performance of the code, I always observe dependency of CPU
>> user time on the presence of other CPU intense processes.  Same CPU-only
>> deterministic process that on the quiet machine completes in 220 user
>> seconds in the presence of, for example, kde rebuild would complete in
>> 261, 266 or even 379 user seconds.  I am talking about times shown by
>> time(1), not actual an execution time.  It's the same time as getrusage(2)
>> returns in ru_utime field.
>>
>> Why time that process takes in user seconds depends on what other
>> processes are running?
>>
>> FreeBSD-8.2 STABLE on i7 CPU @ 9200 @ 2.67GHz.
>
> Some possible factors:
>
> o Intel Turbo Boost, which raises the clock rate of a single core if the
>  other cores are idle.  A single process on an idle system will run faster.
>
> o i7 chips have a shared L3 cache across all cores, so a single process on
>  an idle system will tend to have more of its data in cache compared to a
>  system with multiple processes, so it spends less time waiting for slower
>  physical memory lookups.
>
> o Process accounting isn't exact.  I may be wrong, but I don't think
>  timestamps are taken every time a syscall is invoked and returns.  Some
>  time marked as "user" may actually be "system" time, in which case you may
>  be seeing the effect of contention in the kernel as more processes are
>  run.

I would add hyper-threading to the list. Once you don't have enough
real cores available to do the job, things do tend to slow down,
unless your process is heavily i/o bound. The time process spends on a
hyper-thread when it's not active still counts towards total time
consumed by the process.

--Artem

>
> You may be able to disable Turbo Boot in your BIOS, which you can use to
> determine how much of the single-process speedup is due to that.
>
> Unrelated but still interesting note on your particular CPU:
> http://www.passmark.com/forum/showthread.php?t=2256
>
> --
>        Dan Nelson
>        dnel...@allantgroup.com
> ___
> freebsd-hackers@freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
> To unsubscribe, send any mail to "freebsd-hackers-unsubscr...@freebsd.org"
>
___
freebsd-hackers@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to "freebsd-hackers-unsubscr...@freebsd.org"