$ uname -a Linux treache.rous.org 2.4.19-686 #1 Mon Nov 18 23:59:03 EST 2002 i686 GNU/Linux $ as --version GNU assembler 2.15 Copyright 2002 Free Software Foundation, Inc. This program is free software; you may redistribute it under the terms of the GNU General Public License. This program has absolutely no warranty. This assembler was configured for a target of `i386-linux'. $ dpkg -l binutils Desired=Unknown/Install/Remove/Purge/Hold | Status=Not/Installed/Config-files/Unpacked/Failed-config/Half-installed |/ Err?=(none)/Hold/Reinst-required/X=both-problems (Status,Err: uppercase=bad) ||/ Name Version Description +++-==============-==============-============================================ ii binutils 2.15-6 The GNU assembler, linker and binary utiliti $ md5sum t.s # t.s is included as an attachment to this message 812b0e954fb19ac7f460f570cbdd85bd t.s $ as t.s t.s: Assembler messages: t.s:55: Error: non-constant expression in ".if" statement $
The expression in the .if is most definitely constant, and the assembler had no problem with 43 preceding similar expressions. This bug is sensitive to the precise sequence of macro calls: changing the order or adding or removing calls can make the error message occur on a different line -- possibly several lines -- or not occur at all. My real code has about 450 of these macro calls (it's building a string table), and each time I change it there's about 50% chance that this problem will occur. -zefram
.macro str STRING .long [EMAIL PROTECTED]@start [EMAIL PROTECTED]: .ascii "\STRING" [EMAIL PROTECTED]: .iflt ([EMAIL PROTECTED] - [EMAIL PROTECTED]) - 2 .endif .p2align 2, 0 .endm str "aaa" str "aa" str "aa" str "aaa" str "aa" str "aaaaaaaa" str "aaaaaa" str "aa" str "aa" str "aa" str "aaaaaaaaa" str "aa" str "aa" str "aaaaa" str "aa" str "aaa" str "aaa" str "aa" .long 0 str "aa" str "aa" str "aaaa" str "aaaaaaaa" str "aaa" str "aaa" str "aa" str "aaaaaaaaaaaaaaaaaaaa" str "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa" str "aaaaaaaaaaaaaaaaaaaaaa" str "aaaaaaaaa" str "aaaaaa" .long 0 str "aaaaaaaaaaaa" str "aaaaaaaaaaaaaaaaaaaaa" str "aaaaaaaaaaaaaa" str "aaaaaaaaaaaaaaaa" str "aaaaaaaaaaaaaaaaaaaaaaaa" str "aaaaaaaaaaaaaaaaaaaaaaaa" str "aaaaaaaaaaaaaaaa" str "aaaaaaaaaaaaaaaaaaaaaa" str "aaaaaaaaaa" str "aaaaaaaaaaaaaaaaaaaaaa" str "aaaaaaaaaaaaaaaaaaaaaa" str "aaaaaaaaaaaaaaaaaaaaaaa" str "aaaaaaaaaaaaaaaaaaaaaaa" str "aaaaaaaaaa"
_______________________________________________ bug-binutils mailing list bug-binutils@gnu.org http://lists.gnu.org/mailman/listinfo/bug-binutils