Module: gas-preprocessor
Branch: master
Commit: 010baf65c19386db996d41c391467ecb333c1156

Author:    Martin Storsjo <[email protected]>
Committer: Martin Storsjo <[email protected]>
Date:      Sat Jun 13 09:31:51 2015 +0300

Match the full branch target when checking for local labels

This avoids spurious matches if actual labels contain the pattern
<digits>[bf].

---

 gas-preprocessor.pl |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/gas-preprocessor.pl b/gas-preprocessor.pl
index 9fb3069..cfd0a4b 100755
--- a/gas-preprocessor.pl
+++ b/gas-preprocessor.pl
@@ -874,7 +874,7 @@ sub handle_serialized_line {
             # Don't interpret e.g. bic as b<cc> with ic as conditional code
             if ($cond !~ /|$arm_cond_codes/) {
                 # Not actually a branch
-            } elsif ($target =~ /(\d+)([bf])/) {
+            } elsif ($target =~ /^(\d+)([bf])$/) {
                 # The target is a local label
                 $line = handle_local_label($line, $1, $2);
                 $line =~ s/\b$instr\b/$&.w/ if $width eq "";

_______________________________________________
libav-commits mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-commits

Reply via email to