Page 1 of 1

Some naive questions about Epiphany assembly

PostPosted: Fri Jun 26, 2015 5:36 pm
by snim2
Hi there,

I'm writing some simple assembler programs, and I have run across some problems with compiling and understanding the code in the Epiphany architecture reference manual. There are a few snippets of code that I couldn't get to work. These are:

- The LDR (POSTMODIFY) example on pp 103 fails to compile with the error ldrdpm.s:3: Error: unrecognised form of instruction 'ldrs r31,[r2],#1'
- The LDR (DISPLACEMENT-POSTMODIFY) example on pp 105 fails to compile with the error ldrpm.s:3: Error: unrecognised form of instruction 'ldrs r31,[r2],r1'
- The STR (POSTMODIFY) example on pp 121 fails to compile with the error str_pm.s:3: Error: unrecognised form of instruction 'strs r31,[r2],r1'
- The STR (DISPLACEMENT-POSTMODIFY) example on pp 122 fails to compile with the error str_dpm.s:3: Error: unrecognised form of instruction 'strs r31,[r2],#2


Any form of load or store that deals with shorts seems to result in a syntax error. Have I misunderstood something here?

Many thanks!

Sarah

Re: Some naive questions about Epiphany assembly

PostPosted: Sat Jun 27, 2015 7:59 am
by piotr5
have you tried ldrh instead of ldrs? at least in my manual s is not a valid value for <size> even though the examples suggest that.

Re: Some naive questions about Epiphany assembly

PostPosted: Sat Jun 27, 2015 12:12 pm
by snim2
Works perfectly, many thanks!

Sarah