Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 10 Nov 2019 18:00:40 +0000
From:      g4jht <g4jht@eircom.net>
To:        freebsd-questions@FreeBSD.org
Subject:   will the current FreeBSD C; compile (true) AT&T assembler files, with embedded / delimited comments ?
Message-ID:  <a19534e3-61f0-00d6-6889-3b2ffed2603e@eircom.net>

next in thread | raw e-mail | index | archive | help
Hi,
    I have an oddball question:
I looking for a compiler (not gcc) that can handle things like the 
following snippet,
which is pure AT&T syntax i386 assembler

/----------- start of snippet --------------
/ Allocate new counter
         addl    $4,%eax         / compute ptr to call count (counter.count)
         movl    %eax,(%edx)     /       and store it in caller's ptr
         movl    0(%esp),%edx
         movl    %edx,-4(%eax)   / set proc addr in counter structure

         movl    $1,(%eax)       / init call count (skip increment)
         jmp     .ret
/----------- end of snippet --------------

I do not wish to start changing the source rather I am  looking for a 
compiler that
will process it in unmodified form (and without resorting to 
pre-processor or other "tricks"?
Will the compiler in current FreeBSD do what I want please ?
If it will also accept (pre-ANSI) K&R Whitebook C that would be even 
better.

Note I am not a newbie!

great weekend and regards,
                           Dave





Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?a19534e3-61f0-00d6-6889-3b2ffed2603e>