STM32 ARM toolset advice?

I found t that an ARM (PXA-255 at 400MHz like that in the Triton board) does a FP multiply in about 0.13 microseconds using the Soft-Float libary. (It takes about 10X longer using floating-point emulation in the Linux kernel.)

formatting link

I did find that an AT91SAM7S at 16Mhz using the IAR libraries, had about 5 times the floating point performance of an M68332 at the same clock using the Codewarrior libraries. How much of that is better code and how much is due to a better CPU is open to question.

Mark Borgerson

Reply to
Mark Borgerson
Loading thread data ...

That's about 52 cycles, which is pretty good if it is double multiply.

The M68332 is such a slow CISC that one can do a full floating point multiply on ARM in less than half the time it takes the M68332 to execute one 32x32 multiply instruction.

Wilco

Reply to
Wilco Dijkstra

available,

I think it was only single-precision (32 bits) IEEE-854 format. It is also possible that the soft float library did not properly handle NAN and some other conditions. It was supposedly highly optimized for the array-multiply operations for which it was used (part of an extended Kalman Filter).

I agree. I used to have to worry about the effects of DIV and DIVU instructions on interrupt latency in some low-jitter analog input routines.

I suspect that there is some real art in the design and coding of an ARM FP library so that the operations take full advantage of the shift/rotate and evaluate instructions and scheduling things to keep the pipelines full. I don't think the earlier IAR libraries took advantage of the instruction set as much as they could have as the code is written in C (by P.J. Plauger in 1994, according to the available library source). A lot of the math.h routines also expand 32-bit floats to doubles before doing the math. That's a good way to maintain precision, but not the fastest way to do 32-bit FP math.

Mark Borgerson

Reply to
Mark Borgerson

Look at

formatting link
on how to get much faster ARM floating point under Linux. The speedup was over 10x for the floating point benchmarks used in the article. There was also a big spped improvment going from around 2.x gcc to around

3.x gcc. I cannot recall the exact versions. Someone rewrote the ARM floating point library for gcc in optimized assembler. Most of the comparisons floating around between the comercial ARM compilers and gcc, compares with old gcc 2.x compilers. We are nou at gcc 4.x, which is MUCH faster than the old 2.x versions. It also helps to enable even the minimum level of optimization in gcc.

Regards Anton

Reply to
Anton Erasmus

What makes you think that switching to something other than Windows would invalidate all your knowledge about developing code? Is your experience really so limited that you would lose it all just by running the compiler on a different platform?

So why do you think you couldn't do the same on Linux?

There's a major logic flaw in that line of reasoning. You're effectively saying you stay with Windows because employers all require you do know Unix...

Reply to
Hans-Bernhard Bröker

Erm --- how exactly did you arrive at the conclusion that you couldn't run ARM GCC on Windows, too?

What does the choice of embedded target system have to do with that of the development host platform?

Reply to
Hans-Bernhard Bröker

Running the compiler on Windows is one thing. Running the reset of the build environment required to put together a disk image for a Linux system is a lot more difficult. Building embedded Linux systems is indeed a lot easier on a *nix host.

Yes, you should be able to use Cygwin, but Cygwin is very fragile and doesn't always work well. In my experience, Cygwin is 2-3X slower as well.

--
Grant Edwards                   grante             Yow! FUN is never having to
                                  at               say you're SUSHI!!
                               visi.com
Reply to
Grant Edwards

Well, if the speed is the problem, try DJGPP. This is quite fast, avoids the GUI interface, and generally runs under Windows or MsDos or FreeDos. Not fragile.

--
 [mail]: Chuck F (cbfalconer at maineline dot net) 
 [page]: 
            Try the download section.
Reply to
CBFalconer

By asking the person who sent me the Linux development system if it was possible to run the system under Windows using Cygwin. He told me they didn't know if that would work. That indicated that either it wouldn't work, he didn't know if it would work, or he didn't want to spend the time to get it to work. Thus spaketh the EE PhD from MIT! Who am I, a lowly Msc in Oceanography from Oregon State, to disagree!

(Actually, as I later discussed, I did get it to work using the VirtualBox emulator on my WinXP system.)

Nothing. They were two separate issues. I guess I didn't make that clear. The use of Linux on the embedded system caused many problems-- the first of which was the inability to do PWM output for servo motor control. The hardware didn't have the resources to do the PWM with 10-bit resolution, and it was impossible to do it with bit banging and software delay loops as core interrupts kept extending the pulse width enough to cause serious motor chatter.

Mark Borgerson

Reply to
Mark Borgerson

This happens to be exactly what EMC is doing: EMC being the Enhanced Machine Controller, a software for numerical control of machinery:

formatting link

The EMC people have extensive experience running exactly this kind of jobs. They do with with RT Linux, and have a lot of material on their website on measuring and optimizing latencies for reliable Real Time operation.

--
		Przemek Klosowski, Ph.D.
Reply to
przemek klosowski

In message , Mark Borgerson writes

God save us from Academics!!!! :-)

There are several GCC ARM compilers that run natively on MS Windows.

--
\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\
\/\/\/\/\ Chris Hills  Staffs  England     /\/\/\/\/
\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/
Reply to
Chris H

I'm reminded of a sign once I saw in an engineering lab:

+-----------------------------+ | OK, so you've got a PhD | | -- | | Just don't _touch_ anything | +-----------------------------+
--
Grant Edwards                   grante             Yow! I had pancake makeup
                                  at               for brunch!
                               visi.com
Reply to
Grant Edwards

Have you used any of them? Which was the best? Do they have good debugging support?

Mark Borgerson

Reply to
Mark Borgerson

Back when I was an ensign in the Navy, they used to tell me that the most dangerous thing on a ship was an ensign with a screwdriver!

Mark Borgerson

Reply to
Mark Borgerson

In message , Mark Borgerson writes

Not personally.

No idea.

Not compared to commercial tools

--
\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\
\/\/\/\/\ Chris Hills  Staffs  England     /\/\/\/\/
\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/
Reply to
Chris H

How on earth can you state that conclusion based on no experience and no idea?

Paul

Reply to
Paul Black

A lot of Linux users on our stand last week at ESS told us so. They were looking for solutions for debugging and testing.

I don't use GCC so I don't know which one is the best but I do know talking to various users that many of the options available with the commercial tools are either not available to them or take a lot of time and effort to do (time costs money) and don't give such good results.

Trying to get a decent JTAG with Trace to work with linux is not easy (or possible at all in a lot of cases)

How do you get automated unit testing?

--
\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\
\/\/\/\/\ Chris Hills  Staffs  England     /\/\/\/\/
\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/
Reply to
Chris H

I have used both IAR and Keil tools for several processors, both are good although I do prefer Keil.

I use the Keil ARM7, ARM9, ARM Cortex compiler. Their processor and peripheral simulator is excellent, and so to is their debugging support. The peripheral simulation and debugging facilities make the license worth paying for. (I've not used the IAR Arm tool so can't say what its debugger and simulator if any are like.)

The GCC compiler may or may not be good (from what I have seen it is not a patch on the ARM Real-Vie compiler) but without the processor and peripheral simulation that you get with the Keil tools you only have half a tool set. Since I write software for a living, that would make a ?free? compiler a very expensive option indeed.

As for licenses, I have had a system disk failure and a separate mother board failure this year, Keil reset my node lock license without difficulty both times.

After having tried two tool that were supposed to work under Cygwin one tool I had two one hour sessions with one of their develops trying to get it to work on my PC, the other about 45 minutes with their supposed expert. Neither tool ever did work and as a result of the damage done to my PC by one of the ?Cygwin expert? I had to reformat my PC to get ordinary windows applications to work again. I think at least some of the problems were they expected me to run with no firewall and no antivirus, because their tools were not compatible with these !

I did look at using Linux on a major development for a piece of laboratory equipment, but ended up being frightened off by the enormous costs of a supposedly free platform, and all the extra add on licenses I needed to buy. I instead used WinCE ? fantastic $3 (£3) a license, a few hundred pounds for Visual Studio and your there. Actually I did need platform builder too as I tailored the OS for our hardware, but for under a grand I was away, and the end user was able to test the user interface on a standard HP PDA ? brilliant. Oh and other than Visual Studio you don?t need to buy anything until you?re ready to ship to paying customers. Being able to run the software on a standard PDA was fantastic especially as the hardware was designed in the UK and the Japanese version was targeted at Japan. I even used developers in the USA, and the Ukraine as subcontractors with them not requiring the target hardware. The salesmen also love carrying a demo of the unit on a PDA in their pocket. I guess many will turn their nose up at WinCE but if its right for your application then doing so is foolish.

Regards

Eric

Reply to
Bocote

I have used the RIDE IDE from raisonance which has good debugging support, and which uses gcc as the compiler. The freely downloadable version supports debugging of up to 32K. The full commercial version has no restrictions. ST uses this fortheir circleOS based STM32 dev kit. Look at

formatting link
Rowley also has their own IDE and debuggernment , and uses GCC as the compiler. I have not used this, but people that have seem to like it. With RIDE it is easy to update the gcc compiler to whatever version you wish.

Regards Anton Erasmus

Reply to
Anton Erasmus
?

Chris has a simple and infallible mechanism. Open-source = bad. Expensive = good.

--
 [mail]: Chuck F (cbfalconer at maineline dot net) 
 [page]: 
            Try the download section.
Reply to
CBFalconer

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.