[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [microblaze-uclinux] Bad uClinux performance on Spartan-2e.



Hi Leonid,

Leonid wrote:

We are ready to use everything which will run on Spartan-2e. In order to
boost performance, we have tried to use Microblaze 4 (see auto-config.h
attached); we basically copied Spartan-3e Starter Kit design as far as
we could (cashes are shorter in our case).

We did bump into several issues however:

1) u-boot didn't work if it was compiled with HW multiplication support
(which Microblaze 4 presumably has): it didn't recognize flash, serial
output had junk, etc... - I didn't investigate in depth. To make u-boot
working, I have done the following change:

I don't have any Spartan2 hardware here to test on, however I think what is happening is that HW multipliers are simply not available in any microblaze version, when targetting Spartan2. Someone from Xilinx may be able to confirm.

So, even if using mb v4.00.a and setting C_USE_HW_MUL=1, EDK has just ignored you. However, auto-config has not picked this up, so the resulting .in / .h files just reflect what was asked for (in MHS), not what was produced. Thus, u-boot is compiled to expect HW mul, and none is present in the hardware. Garbage in = garbage out.

The real solution here should be in the microblaze.tcl DRC script - if you are targetting an old FPGA architecture it should error-out if you try to set C_USE_HW_MUL to 1.

This also explains why it worked, but was slow, when you disabled the HW mul support.

[snip]

Looks like there is some problems in using Microblaze 4 on Spartan-2e...
can you suggest anything?

Hmmm.. If someone from Xilinx could confirm the theory about no HW mul in Spartan2, regardless of CPU version, then that would be a good start.

I realise none of this helps your current situation, and "use a modern FPGA" is not a particularly helpful response.

You could make a HW multiplier and hang it off an FSL port, but that won't get the compiler doing the right thing.

If you knew the VHDL component definition for the microblaze multipler, you could potentially drop in your own implementation in microblaze_v4_00_b/hdl/vhdl/mul_unit.vhd. However since it's all encrypted you'd need some help from Xilinx. Plus, there's probably higher level checks on C_FAMILY that enable/disable instantiation of the HW multipler anyway.

Anybody else have any bright ideas?

John
___________________________
microblaze-uclinux mailing list
microblaze-uclinux@xxxxxxxxxxxxxx
Project Home Page : http://www.itee.uq.edu.au/~jwilliams/mblaze-uclinux
Mailing List Archive : http://www.itee.uq.edu.au/~listarch/microblaze-uclinux/