[ nasm-Bugs-2840300 ] Macho alignment broken

View: New views
1 Messages — Rating Filter:   Alert me  

[ nasm-Bugs-2840300 ] Macho alignment broken

by SourceForge.net :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Bugs item #2840300, was opened at 2009-08-19 08:26
Message generated for change (Comment added) made by kkanios
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=106208&aid=2840300&group_id=6208

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: Assembler
Group: None
>Status: Closed
>Resolution: Fixed
Priority: 5
Private: No
Submitted By: Nobody/Anonymous (nobody)
>Assigned to: Keith Kanios (kkanios)
Summary: Macho alignment broken

Initial Comment:
Hi,

after switching to the latest NASM 2.07, my MacOSX program suddenly segfaulted all-over the place.

It turned out that 16-byte alignment doesn't work anymore in the latest NASM 2.07, breaking SSE instructions.

Here is the code snippet I use in the asm file (am I doing something wrong?):

section .data align=16
_ssg_step: dd 0,0,0,0
_ssg_cubelenm1vec: dd 0,0,0,0
_pme_gridbins: dd 0,0,0,0

After linking the NASM created Macho object code with GCC object code, the address of _ssg_step above was 16 byte aligned with my previous NASM version, but is 2 byte aligned with the latest NASM 2.07.

BTW, my previous nasm -v output was
NASM version 0.98.40 (Apple Computer, Inc. build 11) compiled on Jan 14 2007

I don't remember how or why I ended up with the version above, it could mean that I had the alignment problem already previously, and found that Apple provided a fixed/patched NASM version...?

How do others use SSE code in Macho objects?

Thanks for your help,
Elmar


----------------------------------------------------------------------

>Comment By: Keith Kanios (kkanios)
Date: 2009-10-16 22:09

Message:
I've isolated the issue and checked-in a fix. Look for it in NASM 2.08.

----------------------------------------------------------------------

You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=106208&aid=2840300&group_id=6208

------------------------------------------------------------------------------
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference
_______________________________________________
Nasm-bugs mailing list
Nasm-bugs@...
https://lists.sourceforge.net/lists/listinfo/nasm-bugs