		  Linux Interrupt Latency benchmark

	--| Description |--

This Linux kernel module measure the number of CPU tick that pass after
a device driver put _its_ irq line active until the irq handler will be
started.

	--| Compilation |--

-  Edit `./Makefile' and set the KERNEL variable to point to a writable linux
   source tree. You need a writable copy of it since the compilation stage
   need to only `touch` something.
-  Run `make`.

	--| Running |--

To run the benchmark you must `insmod` the module specifying as module
parameter the number of the hardware irq line in which generate the hardware
interrupt. For example something like this:

	# insmod ./lil.o irq=3 num=1 verbose=0

will generate 1 irq on the line 3. The `irq' number is required and _must_
be >=0 and <= 15 since the irq is generated playing with the 8259 that handle
only the first 16 interrupt. `num' change the number of interrupt to generate
and can be every 32bit signed integer > 0. Don' t ask me what does it mean
`verbose' ;-). `verbose' can be 0 or 1.

To read the benchmark results you must run `dmesg`.


	--| Technical details |--

The trick I use to generate the hardware interrupt is to trigger the
edge/level register of the 8259 irq controller so this module is really
i386 specific and not portable. Also the accounting of the time is not
portable due the use of the `rdtsc' asm instruction.

There is the problem of know how much time after the outb() instruction
in gen_irq(), the interrupt got generated. To be sure I account in the irq
latency also the time for the _whole_ outb() instruction that is very
expensive. This way real world can only go faster.

The mean in the report is not very very precise due the lack of fpu.

	--| $Id: README,v 1.10 1998/08/18 18:46:02 andrea Exp $ |--
