flat assembler
Message board for the users of flat assembler.

Index > Windows > SSE code and aligning to paragraph

Author
Thread Post new topic Reply to topic
datkins



Joined: 22 Feb 2015
Posts: 3
Location: United Kingdom
datkins 22 Feb 2015, 09:39
Hi,

Trying to using Fasm to create a dll with some SSE code for video processing, I cannot get align 16 to work with the following format

format PE GUI 4.0 DLL

I used the example of a dll in the fasm code for this, "align 8" is fine, is switch format to

format MS64 coff

then "align 16" is fine

not sure why this would be the case, any pointers?
Post 22 Feb 2015, 09:39
View user's profile Send private message Reply with quote
baldr



Joined: 19 Mar 2008
Posts: 1651
baldr 22 Feb 2015, 09:47
datkins,

You definitely should provide some extra data. Source?
Post 22 Feb 2015, 09:47
View user's profile Send private message Reply with quote
datkins



Joined: 22 Feb 2015
Posts: 3
Location: United Kingdom
datkins 22 Feb 2015, 10:05
Hi,

was trying to align the section to paragraph with this

section 'DATA' data readable writeable align 16

seems the align cannot be done for the section, taken that out and then this works fine,

section 'DATA' data readable writeable
ssetest1: dp 12

align 16
sseTestValue: dp 0h, 0h

had hoped "dp" would allow a pargaoh size constant but realised now its a pointer, never mind back to dq

think I'm heading in the right way at last!
Post 22 Feb 2015, 10:05
View user's profile Send private message Reply with quote
AsmGuru62



Joined: 28 Jan 2004
Posts: 1670
Location: Toronto, Canada
AsmGuru62 22 Feb 2015, 12:59
I may be wrong, but I think sections are already aligned by some value, like 512.
Post 22 Feb 2015, 12:59
View user's profile Send private message Send e-mail Reply with quote
datkins



Joined: 22 Feb 2015
Posts: 3
Location: United Kingdom
datkins 22 Feb 2015, 14:18
you might be right, our other linker has a size for this but fasm is new to me so I was not sure.
Post 22 Feb 2015, 14:18
View user's profile Send private message Reply with quote
revolution
When all else fails, read the source


Joined: 24 Aug 2004
Posts: 20445
Location: In your JS exploiting you and your system
revolution 22 Feb 2015, 14:42
AsmGuru62 wrote:
I may be wrong, but I think sections are already aligned by some value, like 512.
There is more than one alignment. File (the on disk format) alignment is usually 512, and image (the in-memory format) alignment is usually 4096. Native DLLs have different rules and, IIRC, align by default to 32.
Post 22 Feb 2015, 14:42
View user's profile Send private message Visit poster's website Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  


< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2025, Tomasz Grysztar. Also on GitHub, YouTube.

Website powered by rwasa.