OpenCores
no use no use 1/1 no use no use
OR1K Assembly Examples
by CleberGomes on Feb 1, 2013
CleberGomes
Posts: 14
Joined: Feb 1, 2013
Last seen: Sep 9, 2014
Hello All,

I would like to know where I can find example programs in assembly for the OR1K processor. I have downloaded the examples in the OVP site but I am looking for something a little more complex. Thank you and regards.

Cleber
RE: OR1K Assembly Examples
by jeremybennett on Feb 4, 2013
jeremybennett
Posts: 815
Joined: May 29, 2008
Last seen: Jun 13, 2019

Hi cleber,

You can see the start-up code for the newlib library (newlib/libgloss/or32/crt0.S I think). Or1ksim also has small assembler examples in its testsuite.

HTH,

Jeremy

--
Tel: +44 (1590) 610184
Cell: +44 (7970) 676050
SkypeID: jeremybennett
Email: jeremy.bennett@embecosm.com
Web: www.embecosm.com

RE: OR1K Assembly Examples
by CleberGomes on Feb 4, 2013
CleberGomes
Posts: 14
Joined: Feb 1, 2013
Last seen: Sep 9, 2014
Hi Jeremy,

There is also the or1k-support-asm.S file in the newlib/libc/machine/or32 path in the newlib port directory. However, I can´t seem to find the newlib port directory. Would you have a direct link to it you can pass me? Thank you,

Regards,
Cleber.
RE: OR1K Assembly Examples
by CleberGomes on Feb 4, 2013
CleberGomes
Posts: 14
Joined: Feb 1, 2013
Last seen: Sep 9, 2014
Found it! Thanks.
RE: OR1K Assembly Examples
by jeremybennett on Feb 4, 2013
jeremybennett
Posts: 815
Joined: May 29, 2008
Last seen: Jun 13, 2019
Hi Cleber,

Here is the browsable SVN link: http://opencores.org/websvn,filedetails?repname=openrisc&path=%2Fopenrisc%2Ftrunk%2Fgnu-stable%2Fnewlib-1.18.0%2Flibgloss%2For32%2Fcrt0.S.

The development tool chain on GitHub may have a newer version. Someone else might post a link, or ask on IRC (channel #openrisc on freenode.net).

HTH,


Jeremy
RE: OR1K Assembly Examples
by rdaddio on Mar 20, 2013
rdaddio
Posts: 18
Joined: Dec 24, 2005
Last seen: Jul 15, 2021
Hi,
I have some starter asm files at "Misc Stuff" on my web page:
http://www.meansoffreedom.com/

The kernel and lib files mentioned by Jeremy do much more of course. The idea of my starter files was to try and help beginners get started with OR assembly. They may be a litte stale but provide some insight into using the GNU AS & etc.

HTH,

Rich d

RE: OR1K Assembly Examples
by CleberGomes on Apr 8, 2013
CleberGomes
Posts: 14
Joined: Feb 1, 2013
Last seen: Sep 9, 2014
Hello Jeremy, rdaddio,

My name is Cleber. I am a researcher at the Brazilian Federal Institute of Metrology. We are starting a new field of research on microprocessors, and I just bought the FPGA Development Board from OpenCores with the OpenRISC processor SoC design embedded. I am trying to compile a assembler file to run on the board. I compiled some C files and run them without any problems using:
or32-elf-gcc �mboard=ordb2a cfile.c �o cfile_hw
I, of course, tried something like this for asm files:
or32-elf-as �mboard=ordb2a cfile.c �o cfile_hw
But it didn´t work. Do you guys know how I can compile asm files for the board? And where I can maybe find some nice examples on a tutorial format? Any help would be appreciated! Jeremy, I will be trying to reach you by direct mail, if you don´t mind. Thanks a lot in advance.
Best regards,
Cleber Gomes.
RE: OR1K Assembly Examples
by CleberGomes on Apr 8, 2013
CleberGomes
Posts: 14
Joined: Feb 1, 2013
Last seen: Sep 9, 2014
ERRATA:
or32-elf-as �mboard=ordb2a asmfile.S �o asmfile_hw
sorry :-)
RE: OR1K Assembly Examples
by rdaddio on Apr 25, 2013
rdaddio
Posts: 18
Joined: Dec 24, 2005
Last seen: Jul 15, 2021
Hi Cleber, Sorry to take so long to reply was traveling. Did your questions get answered out-of-band by Jeremy?
no use no use 1/1 no use no use
© copyright 1999-2025 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.