flat assembler
Message board for the users of flat assembler.
![]() Goto page Previous 1, 2, 3 ... 19, 20, 21 ... 31, 32, 33 Next |
Author |
|
revolution 17 Sep 2010, 08:23
Version 1.20 now available:
Quote: v1.20 2010-Sep-17 |
|||
![]() |
|
den_po 17 Sep 2010, 12:30
it works now. thanks.
|
|||
![]() |
|
revolution 22 Sep 2010, 08:47
den_po: The ldr opcode cannot load from unaligned address in thumb mode. Use like this:
Code: code16 org 0x12701B04 ldr r4,[.1] ldr r0,[undefinedlabel] dw 0 db 10,0 align 4 .1: dw 0 |
|||
![]() |
|
revolution 22 Sep 2010, 08:55
Perhaps I should explain why you get the error "code cannot be generated".
Because you have not set the PROCESSOR version fasmarm will assume you have a v7 capable CPU. With v7 code there are two options for the ldr opcode, one is an hword instruction (limited to addresses in a multiple of 4) and the other is a "wide" word instruction with byte granularity.
Code: ldr.w r4,[.1] |
|||
![]() |
|
den_po 22 Sep 2010, 09:07
i think error message must be more informative
|
|||
![]() |
|
revolution 22 Sep 2010, 09:15
Do you have a suggestion?
BTW: This message is generated by the fasm portion of the code. The fasmarm code does not generate this error. So I would have to patch fasm in some way to change it. |
|||
![]() |
|
revolution 24 Sep 2010, 00:30
I've experimented with various ways to avoid the infinite loop created by some code sequences and I'm pleased with one particular method. If the assembler gets to a third repetition at the same state then code takes action and uses wide instructions in situations where the narrow instructions are causing problems.
For most cases this allows the natural settling of label values to occur without taking action too fast and forcing wide instructions prematurely. While at the same time not going endlessly around in circles hoping for a miracle to save it. Of course there are still a few pathological cases where the code makes a sub-optimal choice but I doubt these occur much in real code. And if the user desperately wants absolutely optimal code then they would probably be using the .n and .w overrides anyway to get precisely what they need. My feeling is it is more important to get the code compiled. I guess the principle I'm following here is: "Find a way to create what the user asked for and not force them to always decide how to optimise it in case of trouble". Sometimes the user doesn't want to be bothered with optimisation when first writing code. If they are following the "get it working, then get it fast" paradigm then automatically solving the "code cannot be generated" problem helps to get them there without undue complaining by the assembler. Later the user can decide to hand optimise if they find fasmam created something badly over-bloated for their liking. Anyhow, I'll delay before putting this into the download in case there is something I have overlooked. Comments, criticisms and suggestions are welcome. |
|||
![]() |
|
revolution 17 Oct 2010, 12:30
Version 1.21 now available:
Quote: v1.21 2010-Oct-17 |
|||
![]() |
|
Tyler 17 Oct 2010, 12:48
revolution wrote: Do you have a suggestion? |
|||
![]() |
|
den_po 14 Nov 2010, 20:51
it's me again
a.asm Code: include "a.inc"
nop a.inc Code: format ELF dwarf executable
processor 0x3ff flat assembler for ARM version 1.69.25 (1466271 kilobytes memory) Unhandled exception at 0x0040cdda in FASMARM.EXE: 0xC0000005: Access violation reading location 0x00000001. |
|||
![]() |
|
revolution 23 Nov 2010, 14:10
The error can be minimally described with:
Code: format ELF dwarf executable nop |
|||
![]() |
|
revolution 23 Nov 2010, 23:21
Version 1.22 now available:
Quote: v1.22 2010-Nov-24 |
|||
![]() |
|
SFeLi 29 Apr 2011, 19:38
Code: format binary virtual at 0x00100000 foo: bl 0x00020000 load foo_instr dword from foo end virtual fasmarm wrote: C:\Programs\fasmarm>fasmarm foo.asm What’s wrong? |
|||
![]() |
|
revolution 30 Apr 2011, 01:11
SFeLi wrote:
|
|||
![]() |
|
SFeLi 30 Apr 2011, 09:01
revolution wrote: dword is a 64 bit value Thank you. |
|||
![]() |
|
edfed 08 May 2011, 14:44
i think it is time to tell everybody that:
Finally, Apple don't bought ARM. ![]() nobody pointed it here, and then, a lot of us still believe ARM is apple property. |
|||
![]() |
|
den_po 30 Jul 2011, 11:17
something wrong with dwarf again.
i want to add some patch to the compiler but when i add only 10 bytes of code/data to ANY place (fasmarm 1.22 + fasm 1.69.25) it fails at "call assembler". |
|||
![]() |
|
revolution 30 Jul 2011, 11:25
Post your code please.
|
|||
![]() |
|
den_po 30 Jul 2011, 18:51
Code: format ELF dwarf executable nop it fails when i add 10 or more bytes to any place before include '..\armv7.inc'. try to add 10 characters to copyright string. |
|||
![]() |
|
Goto page Previous 1, 2, 3 ... 19, 20, 21 ... 31, 32, 33 Next < Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2025, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.