llvm/test/Transforms/GCOVProfiling: Avoid to parse backslashes in MDString. Use %/T instead of %T.

LLVM Parser decodes "\bb" as hex in "C:\bb-win7\buildername\build...", with MDString.

See also, http://llvm.org/docs/LangRef.html#metadata-nodes-and-metadata-strings

This reverts r221270, "Disable 3 tests in llvm/test/Transforms/GCOVProfiling/ for now. Investigating."

FIXME: Please check EC in GCOVProfiler::emitProfileNotes().
llvm-svn: 221334
This commit is contained in:
NAKAMURA Takumi 2014-11-05 06:29:05 +00:00
parent 5026722287
commit 61b2f48453
3 changed files with 3 additions and 9 deletions

View File

@ -1,11 +1,9 @@
; RUN: echo '!16 = metadata !{metadata !"%T/global-ctor.ll", metadata !0}' > %t1 ; RUN: echo '!16 = metadata !{metadata !"%/T/global-ctor.ll", metadata !0}' > %t1
; RUN: cat %s %t1 > %t2 ; RUN: cat %s %t1 > %t2
; RUN: opt -insert-gcov-profiling -disable-output < %t2 ; RUN: opt -insert-gcov-profiling -disable-output < %t2
; RUN: not grep '_GLOBAL__sub_I_global-ctor' %T/global-ctor.gcno ; RUN: not grep '_GLOBAL__sub_I_global-ctor' %T/global-ctor.gcno
; RUN: rm %T/global-ctor.gcno ; RUN: rm %T/global-ctor.gcno
; REQUIRES: shell
@x = global i32 0, align 4 @x = global i32 0, align 4
@llvm.global_ctors = appending global [1 x { i32, void ()*, i8* }] [{ i32, void ()*, i8* } { i32 65535, void ()* @_GLOBAL__sub_I_global-ctor.ll, i8* null }] @llvm.global_ctors = appending global [1 x { i32, void ()*, i8* }] [{ i32, void ()*, i8* } { i32 65535, void ()* @_GLOBAL__sub_I_global-ctor.ll, i8* null }]

View File

@ -1,11 +1,9 @@
; RUN: echo '!9 = metadata !{metadata !"%T/linkagename.ll", metadata !0}' > %t1 ; RUN: echo '!9 = metadata !{metadata !"%/T/linkagename.ll", metadata !0}' > %t1
; RUN: cat %s %t1 > %t2 ; RUN: cat %s %t1 > %t2
; RUN: opt -insert-gcov-profiling -disable-output < %t2 ; RUN: opt -insert-gcov-profiling -disable-output < %t2
; RUN: grep _Z3foov %T/linkagename.gcno ; RUN: grep _Z3foov %T/linkagename.gcno
; RUN: rm %T/linkagename.gcno ; RUN: rm %T/linkagename.gcno
; REQUIRES: shell
define void @_Z3foov() { define void @_Z3foov() {
entry: entry:
ret void, !dbg !8 ret void, !dbg !8

View File

@ -1,4 +1,4 @@
; RUN: echo '!9 = metadata !{metadata !"%T/version.ll", metadata !0}' > %t1 ; RUN: echo '!9 = metadata !{metadata !"%/T/version.ll", metadata !0}' > %t1
; RUN: cat %s %t1 > %t2 ; RUN: cat %s %t1 > %t2
; RUN: opt -insert-gcov-profiling -disable-output < %t2 ; RUN: opt -insert-gcov-profiling -disable-output < %t2
; RUN: head -c8 %T/version.gcno | grep '^oncg\*204' ; RUN: head -c8 %T/version.gcno | grep '^oncg\*204'
@ -12,8 +12,6 @@ define void @test() {
ret void, !dbg !8 ret void, !dbg !8
} }
; REQUIRES: shell
!llvm.gcov = !{!9} !llvm.gcov = !{!9}
!llvm.dbg.cu = !{!0} !llvm.dbg.cu = !{!0}
!llvm.module.flags = !{!12} !llvm.module.flags = !{!12}