Sign in

username:

password:



Not a member?

Search Comp.Arch.Embedded



Search tips

embedded by Keywords

68HC11 | 68HC12 | 8051 | 8052 | ARM | ARM7 | Asic | AT91 | AT91RM9200 | Atmel | AVR | AVRStudio | Bootloader | CFP | CompactFlash | Cygnal | Cypress | Dataflash | DSP | eCos | EEPROM | Embedded Linux | Emulator | Endian | Ethernet | Firewire | FPGA | Freescale | GCC | GNUARM | GSM | H8 | HDLC | I2C | Infineon | Interrupts | Java | JTAG | LCD | LED | LPC2000 | MCU | Microchip | MMC | MPLAB | MSP430 | PC104 | PCB | PCI | PCMCIA | PowerPC | Rabbit | RS232 | RS485 | RTOS | SBC | SDRAM | Sensor | SPI | STK500 | UART | UML | USART | USB | Verilog | VHDL | VxWorks | Xilinx

Discussion Groups

Discussion Groups | Comp.Arch.Embedded | Is 'for' better in Vxworks ?

There are 2 messages in this thread.

You are currently looking at messages 0 to 2.

Is 'for' better in Vxworks ? - karthikbalaguru - 07:00 18-10-07



Hi,

How many cycles does memcpy require in VxWorks w.r.t Arm Processor.

Is 'for' better compared to 'memcpy' in VxWorks ? Any ideas ?

Thx in advans,
Karthik Balaguru


Re: Is 'for' better in Vxworks ? - Wilco Dijkstra - 08:29 18-10-07

"karthikbalaguru" <k...@gmail.com> wrote in message 
news:1...@k35g2000prh.googlegroups.com...
> Hi,
>
> How many cycles does memcpy require in VxWorks w.r.t Arm Processor.

Although some RTOSes supply their own variants, memcpy is part of
the compiler and libraries, and it is typically best to use the latter. If you
chose a good compiler you simply do not have to worry about this.

How fast memcpy is depends a lot on the particular implementation
chosen, the goals (codesize, performance), the alignment and size
of the data you are copying and last but not least the CPU used and
its memory system ("ARM" is nowhere near specific enough).

> Is 'for' better compared to 'memcpy' in VxWorks ? Any ideas ?

Memcpy is best implemented in highly optimised assembler copying
16+ bytes per iteration, taking less than 1 cycle per byte copied.
A "for" loop copying one byte at a time is about 10 times as slow...
It's best to do some benchmarking yourself with the kind of copies you need.

Wilco