Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Software Project: converting ARM7 instructions into integers quickly?

Status
Not open for further replies.

bishboria

Programmer
Jan 1, 2007
5
0
0
GB
Hi everyone.

To complete my Masters Degree I made a piece of software that simulated a multicore processor (written in java.)

The simulator "executes" a cutdown version of the ARM7 instrucion set (I don't need software interrupt instructions or superuser mode instructions, just basic jump, add, subtract, etc)

To cut to the chase, when testing my software I had to hand write programs. This involved a lot of time looking at the instruction set format and writing down the appropriate value for each of the bits. I would then take this 32 bit list and convert it drectly into an integer. (Using the integer means I can extract the data back out quickly during execution time using bitwise operations and shifts.)

I can easily find tools to change C code into ARM7, but I can't find anything that will change the ARM7 code into an integer.

Can anyone help?

Originally the simulator could reach about 500Hz, which was OK. But I have recently made a, literally, tiny modification and it has made the speed go up to 46500Hz!

With this new speed, I would like to test the simulator with larger programs, hence the need for a faster way to create them!

Many thanks in advance.
 
> I can easily find tools to change C code into ARM7
Such as?

In gcc terms, it might be something like
[tt]gcc -c test.c
ld -b binary -o test.bin test.o
[/tt]
Most linker (ld) output file formats are complex things - full of relocation and symbol table information. But simple binary formats are essentially little more than memory images of the compiled program in memory. With a bit of effort, your program should be capable of reading these directly so you don't have to do any manual translation yourself.

--
 
go to
there you can download the cross compiler to change C into ARM7 assembly.

using the compile options you can choose which architecture you want to run it on.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top