]> granicus.if.org Git - llvm/commitdiff
[UpdateTestChecks] Allow Lbegin_func without a leading period
authorMartin Storsjo <martin@martin.st>
Mon, 29 Apr 2019 20:25:56 +0000 (20:25 +0000)
committerMartin Storsjo <martin@martin.st>
Mon, 29 Apr 2019 20:25:56 +0000 (20:25 +0000)
On mingw/i686, local labels don't start with a leading period.

Also escape the leading period, as it previously could match
any char.

Differential Revision: https://reviews.llvm.org/D61254

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@359497 91177308-0d34-0410-b5e6-96231b3b80d8

utils/UpdateTestChecks/asm.py

index 115d40051e5be1fafe7055a1a40b58030863bdb5..c14417a1644ff055aa5107f39c66e8a8bf099f83 100644 (file)
@@ -14,7 +14,7 @@ else:
 ##### Assembly parser
 
 ASM_FUNCTION_X86_RE = re.compile(
-    r'^_?(?P<func>[^:]+):[ \t]*#+[ \t]*@(?P=func)\n(?:\s*.Lfunc_begin[^:\n]*:\n)?[^:]*?'
+    r'^_?(?P<func>[^:]+):[ \t]*#+[ \t]*@(?P=func)\n(?:\s*\.?Lfunc_begin[^:\n]*:\n)?[^:]*?'
     r'(?P<body>^##?[ \t]+[^:]+:.*?)\s*'
     r'^\s*(?:[^:\n]+?:\s*\n\s*\.size|\.cfi_endproc|\.globl|\.comm|\.(?:sub)?section|#+ -- End function)',
     flags=(re.M | re.S))