[llvm] Use yaml2obj for llvm-cov tests to see covmap (PR #115886)
NAKAMURA Takumi via llvm-commits
llvm-commits at lists.llvm.org
Wed Nov 13 06:22:44 PST 2024
https://github.com/chapuni updated https://github.com/llvm/llvm-project/pull/115886
>From 9d07f62b627cdc94cc7c472343cda291b155c137 Mon Sep 17 00:00:00 2001
From: NAKAMURA Takumi <geek4civic at gmail.com>
Date: Wed, 13 Nov 2024 00:23:24 +0900
Subject: [PATCH 1/3] Use yaml2obj for llvm-cov tests to see covmap
---
.../llvm-cov/Inputs/branch-c-general.o32l | Bin 16272 -> 0 bytes
.../llvm-cov/Inputs/branch-c-general.yaml | 160 +++++++++
.../{ => Inputs}/branch-logical-mixed.cpp | 13 +-
.../llvm-cov/Inputs/branch-logical-mixed.o32l | Bin 4884 -> 0 bytes
.../llvm-cov/Inputs/branch-logical-mixed.yaml | 50 +++
.../llvm-cov/{ => Inputs}/branch-macros.cpp | 14 +-
.../tools/llvm-cov/Inputs/branch-macros.o32l | Bin 4456 -> 0 bytes
.../tools/llvm-cov/Inputs/branch-macros.yaml | 61 ++++
.../Inputs/branch-showBranchPercentage.c | 58 +++
.../Inputs/branch-showBranchPercentage.o32l | Bin 3284 -> 0 bytes
.../Inputs/branch-showBranchPercentage.yaml | 39 ++
.../llvm-cov/Inputs/branch-templates.cpp | 38 ++
.../llvm-cov/Inputs/branch-templates.o32l | Bin 5408 -> 0 bytes
.../llvm-cov/Inputs/branch-templates.yaml | 72 ++++
.../llvm-cov/Inputs/mcdc-const-folding.o | Bin 34528 -> 0 bytes
.../llvm-cov/Inputs/mcdc-const-folding.yaml | 333 ++++++++++++++++++
llvm/test/tools/llvm-cov/Inputs/mcdc-const.o | Bin 5208 -> 0 bytes
.../tools/llvm-cov/Inputs/mcdc-const.yaml | 57 +++
.../tools/llvm-cov/Inputs/mcdc-general-18.o | Bin 6456 -> 0 bytes
.../llvm-cov/Inputs/mcdc-general-18.yaml | 57 +++
.../test/tools/llvm-cov/Inputs/mcdc-general.o | Bin 6544 -> 0 bytes
.../tools/llvm-cov/Inputs/mcdc-general.yaml | 57 +++
llvm/test/tools/llvm-cov/Inputs/mcdc-macro.o | Bin 6408 -> 0 bytes
.../tools/llvm-cov/Inputs/mcdc-macro.yaml | 69 ++++
llvm/test/tools/llvm-cov/Inputs/mcdc-maxbs.o | Bin 4112 -> 0 bytes
.../tools/llvm-cov/Inputs/mcdc-maxbs.yaml | 57 +++
llvm/test/tools/llvm-cov/Inputs/yaml.makefile | 16 +
.../test/tools/llvm-cov/branch-c-general.test | 11 +-
.../tools/llvm-cov/branch-export-json.test | 6 +-
.../tools/llvm-cov/branch-export-lcov.test | 10 +-
.../tools/llvm-cov/branch-logical-mixed.test | 12 +
llvm/test/tools/llvm-cov/branch-macros.test | 12 +
.../tools/llvm-cov/branch-noShowBranch.test | 5 +-
.../llvm-cov/branch-showBranchPercentage.c | 77 ----
.../llvm-cov/branch-showBranchPercentage.test | 25 ++
...ch-templates.cpp => branch-templates.test} | 41 +--
llvm/test/tools/llvm-cov/mcdc-const.test | 8 +-
.../test/tools/llvm-cov/mcdc-export-json.test | 3 +-
llvm/test/tools/llvm-cov/mcdc-general-18.test | 13 +-
.../tools/llvm-cov/mcdc-general-none.test | 13 +-
llvm/test/tools/llvm-cov/mcdc-general.test | 13 +-
llvm/test/tools/llvm-cov/mcdc-macro.test | 3 +-
llvm/test/tools/llvm-cov/mcdc-maxbs.test | 4 +-
43 files changed, 1235 insertions(+), 172 deletions(-)
delete mode 100644 llvm/test/tools/llvm-cov/Inputs/branch-c-general.o32l
create mode 100644 llvm/test/tools/llvm-cov/Inputs/branch-c-general.yaml
rename llvm/test/tools/llvm-cov/{ => Inputs}/branch-logical-mixed.cpp (80%)
delete mode 100644 llvm/test/tools/llvm-cov/Inputs/branch-logical-mixed.o32l
create mode 100644 llvm/test/tools/llvm-cov/Inputs/branch-logical-mixed.yaml
rename llvm/test/tools/llvm-cov/{ => Inputs}/branch-macros.cpp (70%)
delete mode 100644 llvm/test/tools/llvm-cov/Inputs/branch-macros.o32l
create mode 100644 llvm/test/tools/llvm-cov/Inputs/branch-macros.yaml
create mode 100644 llvm/test/tools/llvm-cov/Inputs/branch-showBranchPercentage.c
delete mode 100644 llvm/test/tools/llvm-cov/Inputs/branch-showBranchPercentage.o32l
create mode 100644 llvm/test/tools/llvm-cov/Inputs/branch-showBranchPercentage.yaml
create mode 100644 llvm/test/tools/llvm-cov/Inputs/branch-templates.cpp
delete mode 100644 llvm/test/tools/llvm-cov/Inputs/branch-templates.o32l
create mode 100644 llvm/test/tools/llvm-cov/Inputs/branch-templates.yaml
delete mode 100644 llvm/test/tools/llvm-cov/Inputs/mcdc-const-folding.o
create mode 100644 llvm/test/tools/llvm-cov/Inputs/mcdc-const-folding.yaml
delete mode 100644 llvm/test/tools/llvm-cov/Inputs/mcdc-const.o
create mode 100644 llvm/test/tools/llvm-cov/Inputs/mcdc-const.yaml
delete mode 100644 llvm/test/tools/llvm-cov/Inputs/mcdc-general-18.o
create mode 100644 llvm/test/tools/llvm-cov/Inputs/mcdc-general-18.yaml
delete mode 100644 llvm/test/tools/llvm-cov/Inputs/mcdc-general.o
create mode 100644 llvm/test/tools/llvm-cov/Inputs/mcdc-general.yaml
delete mode 100644 llvm/test/tools/llvm-cov/Inputs/mcdc-macro.o
create mode 100644 llvm/test/tools/llvm-cov/Inputs/mcdc-macro.yaml
delete mode 100644 llvm/test/tools/llvm-cov/Inputs/mcdc-maxbs.o
create mode 100644 llvm/test/tools/llvm-cov/Inputs/mcdc-maxbs.yaml
create mode 100644 llvm/test/tools/llvm-cov/Inputs/yaml.makefile
create mode 100644 llvm/test/tools/llvm-cov/branch-logical-mixed.test
create mode 100644 llvm/test/tools/llvm-cov/branch-macros.test
delete mode 100644 llvm/test/tools/llvm-cov/branch-showBranchPercentage.c
create mode 100644 llvm/test/tools/llvm-cov/branch-showBranchPercentage.test
rename llvm/test/tools/llvm-cov/{branch-templates.cpp => branch-templates.test} (54%)
diff --git a/llvm/test/tools/llvm-cov/Inputs/branch-c-general.o32l b/llvm/test/tools/llvm-cov/Inputs/branch-c-general.o32l
deleted file mode 100644
index 7b3151184817805fefe16e9023f69501e552f067..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001
literal 16272
zcmeHNdw5$%m7lp+k}X at ZE!py0iImum?L at X@OSVPhCbBIh&Z|kAq-mSt_?6hLU&Kn2
z0?TG;mp&HS^g%a;bm`K<vb22LWy7`~+ineg1<2-eXn;^s2yFLr1S~|*b_2`O{hhgY
zr0W|y^soJEC()fbGr#*gXU?2?+)4gCzA3>uXEJeC&$1F at v#UglH7v4vb_lI&f5X at e
zen&186!B13nkh3W<}OYT at lB$vxMx!q_mJLVfn;-U)FqpHY8_FLjzH?-HJ^9}Y`I{|
zJqwPrmvWiL$d8=8<X|VLE>+}bM|evt&G-qF&!$S<x#@D|O7lGE&OebVed=tgyv7Pl
zZn~cJq?yHXBscBD+vPQUS#G+>u0jqn<w)Ck>#@y=@1 at wO>NK})Nwb_+Qf%Lu6uXVL
z at b*NS*<MB&8n>TKxkG1D1-J1C@$uHPsghG<frhGt?v2n576ul_P~!<;Vcqr<c<;oe
zt?b05?K6e5XL4RWz2V)bd}qG;?RUTI>*+2 at e|e4a`kN_r`}1?kv2V`tqhx&%Jjaf%
zh3`(J6u0e}7cN}9U;60q*QB>+Q!E6({*t$n9q at RlWjT9sHkIqP3g6~kHG}fIr<bH#
z^>NTVKby*1El0`bzM)zhqdbg?!(E||iUU%CTcQfwhhLETr!xApqs?2v;W&)Z$H at BG
za&2s8PzI-;rPn%SjRQ56O%3PSi at XJXDwu&Zn_5!BL*&&Nl=>5=Q!LKX>uo$7Pc!Q`
zAniZJTP4C>GFpvs0k))MHdUH=v$TY*JTuEz=A71;S^6-1QrYx_Ib~)2>21}}hN!GW
zzm~Plrb^trl}1<ga9JDp(AKzpHdO-~>)Y&NobyDK<q7NzT4vBP1Ju+Df1D$aWaCzj
z%8?8AvB`^8i)3bCwYXtTuB@@Z=j$@_!uEB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llvm/test/tools/llvm-cov/Inputs/branch-c-general.yaml
new file mode 100644
index 00000000000000..c601280912f05e
--- /dev/null
+++ b/llvm/test/tools/llvm-cov/Inputs/branch-c-general.yaml
@@ -0,0 +1,160 @@
+--- !ELF
+FileHeader:
+ Class: ELFCLASS32
+ Data: ELFDATA2LSB
+ Type: ET_REL
+ Machine: EM_ARM
+ Flags: [ EF_ARM_EABI_VER5 ]
+ SectionHeaderStringTable: .strtab
+Sections:
+ - Name: '__llvm_covfun (7)'
+ Type: SHT_PROGBITS
+ AddressAlign: 0x8
+ Content: D7878914FBE99B075B000000D136449C106D04009FD374D96F4D6D1A01000401050109010D010D0D010715080203020F0016200501000F0016050018001B05001C009D8080800805001D010407020A000F200901000A000F09001001858080800809010500080F010600080F00100018200D0100100018
+ - Name: '__llvm_covfun (4)'
+ Type: SHT_PROGBITS
+ AddressAlign: 0x8
+ Content: 83AD05A5F1438E684401000052D33558163C11449FD374D96F4D6D1A01001401050509090D05090509050946110509111546110509461105094611050942194611050921252D312C0111150E02030113001A2005010013001A05001C001F05002000A1808080080500210B04050109000E2009460009000E09000F009080808008090010020609010B000C200D0A000B000C0D000D008E808080080D000E0010460106008C8080800846000C0406460010001520114200100015110016009780808008110017020611010B000C201522000B000C15000D008E8080800815000E0010420106008C8080800842000C020642010B000C20193E000B000C19000D008E8080800819000E0010050309000A050009000F2000000009000A21000E000F20254A000E000F1D00100091808080081D00110013050109000A050009000F2000000009000A2D000E000F204E31000E000F2900100091808080082900110013
+ - Name: '__llvm_covfun (5)'
+ Type: SHT_PROGBITS
+ AddressAlign: 0x8
+ Content: 0449C70428C57369320100003D5C2D0E4B13F9279FD374D96F4D6D1A01001C01050B0D0109010D090D090D090D090D2611090D0115011901195B1D01195B1D01195B1D01195B1D01195B1D0119011D011D011D6E21011D260121141802010307000820050200070008050009008A8080800805000A000C06020A001120090E000A00110900120093808080080900130604090209000F200D260009000F0D00100187808080080D0107000C26000C0185808080082601050204260009000E2011220009000E11000F018780808008110107000F010307000820152A00070008150009008A8080800815000A000C5B020605045B0109000F201D560009000F1D00100187808080081D0107000D56000D008E8080800856000E028780808008560207000A56010C001320196E000C00136E020302026E0007000820216A00070008210009008A8080800821000A000C
+ - Name: '__llvm_covfun (3)'
+ Type: SHT_PROGBITS
+ AddressAlign: 0x8
+ Content: 55947829059F255EDE0100001B9C495D3463E1D09FD374D96F4D6D1A01001F010500090D111915191D1915292D292D292D732D29394A31732D293941453D453D414A31732D29396A316F2D7351293966496A316F2D73512939004D515542013B0E2F0201030F0014200502000F0014000016001905001A009B8080800805001B04040003050104000009000A2009060009000A09000B008C8080800809000C000E0D0301030D0D0107000820110A00070008110009008A8080800811000A000C000403210219000A000B201516000A000B15000C008D8080800815000D03041901030204190109000A201D120009000A1D000B008C808080081D000C000E160303000D21000D0181808080082101011B022501011A022901011902290207000C202D220007000C2D000D0185808080082D0105000F22000F02838080800822020314024A000A000F203146000A000F3100100091808080083100110A0435010309040001100691808080083D01050111203D3B0005000B410205011220413F0005000B45020501112045430005000B460503080266000F0015204962000F0015510017001A49001B009C8080800849001C06045101140383808080080002050304000009000A204D760009000A4D000B008C808080084D000C000E5101030204510109000A20557A0009000A55000B008C8080800855000C000E
+ - Name: '__llvm_covfun (9)'
+ Type: SHT_PROGBITS
+ AddressAlign: 0x8
+ Content: 7129CA3C268292BFC00100003E688383C9A099009FD374D96F4D6D1A01002507390B250511030D173911251F41232D1D251519151D3341372D1525151D7721151D4B41772D151D252973417725151D2D31393D3541732D7725151D35418301453541030D030D920149030D38016C112502000417028A80808008090103010A2009000003000A05010A0383808080080503031C0203003F0046200D9201003F0046130048004B0D004C00CD808080080D004D1704000119148F80808008150105130F20151B0005000B15010B000C201926000B000C19000D008E8080800819000E0010770205020C201D2F0005000B77010B000C20213E000B000C21000D008E8080800821000E0010250205020F2025470005000B25010B000C202952000B000C29000D008E8080800829000E00102D02050A0F202D570005000B2D010B000C203162000B000C31000D008E8080800831000E001000011203918080800839010702112039000007001339010D000E203D66000D000E3D000F0090808080083D0010001235011103858080800883010305020F350005020F20416F0005000C8301010B001720457E000B0017450018018980808008450109000F92010503020292010007001120498E01000700114900120093808080084900130015
+ - Name: '__llvm_covfun (8)'
+ Type: SHT_PROGBITS
+ AddressAlign: 0x8
+ Content: 3F4D1C6E6087417BB0010000D6FF56B8865A69B69FD374D96F4D6D1A01002F010903050F3D1335172D1B25151D0D110D152B3D2F35332D37250D1D0D15B701190D154B3D4F35532DB701250D151D21633D6735B3012DB7011D0D1525297B3DAF0135B30125B7011D0D152D31AB013DAF012DB30125B7011D0D153539AB0135AF012DB30125B7011D0D153D4131019301131F0203011300192005060013001909001B001E05001F00A0808080080500201C04000115198C808080080D0105180C200D0B000500120D010B000C20111E000B000C11000D008E8080800811000E0010B7010205020C20152700050012B701010B000C20193E000B000C19000D008E8080800819000E00101D0205020C201D47000500201D010B000C20215A000B000C21000D008E8080800821000E0010250405020C20255F0005001325010B000C202972000B000C29000D008E8080800829000E00102D0205020C202D77000500212D010B000C20318A01000B000C31000D008E8080800831000E0010350405020C20358F010005002735010B000C2039A201000B000C39000D008E8080800839000E00103D0205020C203DA7010005000C3D010B000C2041BA01000B000C41000D008E8080800841000E0010
+ - Name: '__llvm_covfun (2)'
+ Type: SHT_PROGBITS
+ AddressAlign: 0x8
+ Content: 59A48AA8899AA358C100000091E33C8FF36C04009FD374D96F4D6D1A01000B01050509090D0511111505212125191D05313135292D1C01B4011A0C02030213001A2005010013001A05001C001F05002000A1808080080500210804050109000E2006090009000E0900120013200A0D00120013050209000E20110E0009000E110012001320151200120013050209000E05000900172016210009000E2100120017201A250012001719001B001C201E1D001B001C050209000E05000900172031220009000E31001200172035260012001729001B001C202D2A001B001C
+ - Name: __llvm_covfun
+ Type: SHT_PROGBITS
+ AddressAlign: 0x8
+ Content: F5953D044B505D13D20000005FD132562FE71EAC9FD374D96F4D6D1A01001201050309090D011101111B1501111519011D011D2F21011D212501290129432D01292D311D01C201150D0203030A000B03000A0015200906000A000B09000F0015200D0A000F001505001601858080800805010500081B020A00111B000A001C201615000A0011150015001C201E190015001C11001D01858080800811010500082F021100122F0011001C20212A00110012210016001C2025320016001C1D001E00211D0022002343020A001143000A001C203E2D000A00112D0015001C2046310015001C29001E00212900220023
+ - Name: '__llvm_covfun (6)'
+ Type: SHT_PROGBITS
+ AddressAlign: 0x8
+ Content: 20E5C369BDF15C7936000000D0D60000000000009FD374D96F4D6D1A0100030105010901090701D1011D0702200502030B00110500120094808080080500140015020018001920090A020B000C0A00100011
+ - Name: '__llvm_covfun (1)'
+ Type: SHT_PROGBITS
+ AddressAlign: 0x8
+ Content: 7DE8E7C47096EB427A00000092EAF0986287F0789FD374D96F4D6D1A01000C0105050905092B0D05092B0D05092B0D05092B0D0509050D0F01DA01170B0203011300192005010013001905001B001E05001F00A08080800805002009042B020806062B040B0010200D26000B00100D00110092808080080D00120017260017018780808008260107010626010E001320092E000E0013
+ - Name: '__llvm_covfun (10)'
+ Type: SHT_PROGBITS
+ AddressAlign: 0x8
+ Content: FAD58DE7366495DB0A00000018000000000000009FD374D96F4D6D1A0100000101F501280F02
+ - Name: '__llvm_covfun (11)'
+ Type: SHT_PROGBITS
+ AddressAlign: 0x8
+ Content: 4CB4F49D6737EBF92B000000D1460000000000009FD374D96F4D6D1A01000101050601E7011B030203011300192005010013001905001B001E05001F00A0808080080500200104
+ - Name: __llvm_covmap
+ Type: SHT_PROGBITS
+ AddressAlign: 0x8
+ Content: 000000001B0000000000000003000000011800172F746D702F6272616E63682D632D67656E6572616C2E6300
+ - Name: __llvm_prf_names
+ Type: SHT_PROGBITS
+ AddressAlign: 0x1
+ Content: A6010073696D706C655F6C6F6F707301636F6E646974696F6E616C73016561726C795F6578697473016A756D7073017377697463686573016269675F73776974636801626F6F6C65616E5F6F70657261746F727301626F6F6C6F705F6C6F6F707301636F6E646974696F6E616C5F6F70657261746F7201646F5F66616C6C7468726F756768016D61696E016272616E63682D632D67656E6572616C2E633A7374617469635F66756E63
+ - Type: SectionHeaderTable
+ Sections:
+ - Name: .strtab
+ - Name: '__llvm_covfun (7)'
+ - Name: '__llvm_covfun (4)'
+ - Name: '__llvm_covfun (5)'
+ - Name: '__llvm_covfun (3)'
+ - Name: '__llvm_covfun (9)'
+ - Name: '__llvm_covfun (8)'
+ - Name: '__llvm_covfun (2)'
+ - Name: __llvm_covfun
+ - Name: '__llvm_covfun (6)'
+ - Name: '__llvm_covfun (1)'
+ - Name: '__llvm_covfun (10)'
+ - Name: '__llvm_covfun (11)'
+ - Name: __llvm_covmap
+ - Name: __llvm_prf_names
+ - Name: .symtab
+Symbols:
+ - Name: __llvm_prf_names
+ Type: STT_SECTION
+ Section: __llvm_prf_names
+ - Name: __covrec_135D504B043D95F5u
+ Type: STT_OBJECT
+ Section: __llvm_covfun
+ Binding: STB_WEAK
+ Size: 0xEE
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_42EB9670C4E7E87Du
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (1)'
+ Binding: STB_WEAK
+ Size: 0x96
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_58A39A89A88AA459u
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (2)'
+ Binding: STB_WEAK
+ Size: 0xDD
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_5E259F0529789455u
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (3)'
+ Binding: STB_WEAK
+ Size: 0x1FA
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_688E43F1A505AD83u
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (4)'
+ Binding: STB_WEAK
+ Size: 0x160
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_6973C52804C74904u
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (5)'
+ Binding: STB_WEAK
+ Size: 0x14E
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_795CF1BD69C3E520u
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (6)'
+ Binding: STB_WEAK
+ Size: 0x52
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_79BE9FB148987D7u
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (7)'
+ Binding: STB_WEAK
+ Size: 0x77
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_7B4187606E1C4D3Fu
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (8)'
+ Binding: STB_WEAK
+ Size: 0x1CC
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_BF9282263CCA2971u
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (9)'
+ Binding: STB_WEAK
+ Size: 0x1DC
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_DB956436E78DD5FAu
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (10)'
+ Binding: STB_WEAK
+ Size: 0x26
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_F9EB37679DF4B44Cu
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (11)'
+ Binding: STB_WEAK
+ Size: 0x47
+ Other: [ STV_HIDDEN ]
+...
diff --git a/llvm/test/tools/llvm-cov/branch-logical-mixed.cpp b/llvm/test/tools/llvm-cov/Inputs/branch-logical-mixed.cpp
similarity index 80%
rename from llvm/test/tools/llvm-cov/branch-logical-mixed.cpp
rename to llvm/test/tools/llvm-cov/Inputs/branch-logical-mixed.cpp
index f5f78711244677..0a7d8d89671158 100644
--- a/llvm/test/tools/llvm-cov/branch-logical-mixed.cpp
+++ b/llvm/test/tools/llvm-cov/Inputs/branch-logical-mixed.cpp
@@ -1,6 +1,6 @@
-// RUN: llvm-profdata merge %S/Inputs/branch-logical-mixed.proftext -o %t.profdata
-// RUN: llvm-cov show --show-branches=count %S/Inputs/branch-logical-mixed.o32l -instr-profile %t.profdata -path-equivalence=/tmp,%S %s | FileCheck %s
-// RUN: llvm-cov report --show-branch-summary %S/Inputs/branch-logical-mixed.o32l -instr-profile %t.profdata -show-functions -path-equivalence=/tmp,%S %s | FileCheck %s -check-prefix=REPORT
+
+
+
#include <stdio.h>
#include <stdlib.h>
@@ -81,10 +81,3 @@ int main(int argc, char *argv[])
__llvm_profile_write_file();
return 0;
}
-
-// REPORT: Name Regions Miss Cover Lines Miss Cover Branches Miss Cover
-// REPORT-NEXT: ---
-// REPORT-NEXT: _Z4funcii 77 9 88.31% 68 3 95.59% 80 32 60.00%
-// REPORT-NEXT: main 1 0 100.00% 5 0 100.00% 0 0 0.00%
-// REPORT-NEXT: ---
-// REPORT-NEXT: TOTAL 78 9 88.46% 73 3 95.89% 80 32 60.00%
diff --git a/llvm/test/tools/llvm-cov/Inputs/branch-logical-mixed.o32l b/llvm/test/tools/llvm-cov/Inputs/branch-logical-mixed.o32l
deleted file mode 100644
index a50099716bce95767b945b968ffa7fcb5d034c2f..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001
literal 4884
zcma)9eN0r at 6~E^(;J^wZ3W}>_bVSk0V`dmeAgftWrqzlYO*M^G$N6}`DD#nFU|kax
zw~Jky(#EEw*-cFJ4>#REY|J($+do)MgQ<ViEN#YQKeTb1*mjzjLL0KSiM79T- at A_|
z(X{8yyXWh7&pr3tkC{2!vnNbMLJ^53F|P at csFI%2pkz&=0p8}~OxNrG5UyKz3q|1-
z8!513R+PNkJq7Kvo3t at -zfi34&Rc7|ul~MJTppm-?pdKtK`Ioh;)P<x77B6CDXCS5
zs5Lw*$|x{ZtPbsw_6l#IxZM$HySIMYH8+}jV}{%l4-3T&MxnUQOQD`wQ932HCd1Us
z(Wi<{#uN~RVy7cYr?(9GbX%4wNQL5ScteKj^_n-g8ZqUZLf*133&pUF4g=YaH(;aN
z9q53!?2AHiw~gKnWDu`zqk|5#?k#&zDDJh<dx7-f-E5<M4)kVk<#eIA-$HY}_j?!J
zcg_7m)}!*FYxcV4Mpd at h@wRwfa|L*X`wvCYMy*_ at -#{u9`y5gFyl%uzJ1l8$40#P8
zlh{F3lL7DX)mR@{lbD=k&K at TRWCHI|JMV-e at 1wGUBQ|;j$YXd9+2~^q^dYYs`{$G+
zn^WEftk+ at mIB54cZ1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Ufn;fUJtzJ~0~??(vK37aC7-#=k+=64J6xUd|LZ(5b#A0Z>2o!=cRKXn_c{JsFr
z8E?jsAKO*D9AxKB{arZKJZdc*V=v?7dC1EMY#QV8y{w4)FfELC%n`2+evb8`c-Jw3
zMh;++iuY6Ka$L*)8F0?Mpm5&+h-H;hH5C3HRitnaf#Z0imP6to^WDg#aQ6Xn*6#`G
z#~5A at t{2aNv6B{8<F>=7V!&m~3&&+#6a4C1QT16kF8(sv<MO?&#{C{-o`<4i2%zS`
zHsxE18nDdY4NO_!)|;Yi*~jlTi}Rji`WbM}-!BTML10-?rL#ydD&Myuqb6A=ZkJLV
zxKGi+z2{j*xz=I6_==TvW}Axla|k6SZj|jSUxNEBaE at gc1IX_>Y#c|`kL&bb#|oAO
diff --git a/llvm/test/tools/llvm-cov/Inputs/branch-logical-mixed.yaml b/llvm/test/tools/llvm-cov/Inputs/branch-logical-mixed.yaml
new file mode 100644
index 00000000000000..00135f2e8b9879
--- /dev/null
+++ b/llvm/test/tools/llvm-cov/Inputs/branch-logical-mixed.yaml
@@ -0,0 +1,50 @@
+--- !ELF
+FileHeader:
+ Class: ELFCLASS32
+ Data: ELFDATA2LSB
+ Type: ET_REL
+ Machine: EM_ARM
+ Flags: [ EF_ARM_EABI_VER5 ]
+ SectionHeaderStringTable: .strtab
+Sections:
+ - Name: __llvm_covfun
+ Type: SHT_PROGBITS
+ AddressAlign: 0x8
+ Content: F0A0ED2C305C0BB3C0030000F834CF5F518FC8834287299580773304010030012525291D2115190D110509014D4D5145493D4135392D31017D7D8101758501850189016D8D018D019101659501950199015D9D019D01A10155A501A501A90101D501D501D901CD01DD01DD01E101C501E501E501E901BD01ED01ED01F101B501F501F501F901AD01FD01FD018102018502018502018502018902018902018902018D02018D02018D020191020191020191027D010819430201080C000E01000C010E01000C020E01000C030E01000C040E202502000C000E25010C000E202906000C000E1D010C000E20210A000C000E15010C000E20190E000C000E0D010C000E201112000C000E05010C000E200916000C000E01020C000E01000C010E01000C020E01000C030E01000C040E201A4D000C000E4D010C000E201E51000C000E45010C000E202249000C000E3D010C000E202641000C000E35010C000E202A39000C000E2D010C000E202E31000C000E01020C011001000C031001000C051001000C071001000C091001000D000F207D32000D000F7D010D000F20810136000D000F75010C011075000D000F2085013A000D000F8501010D000F2089013E000D000F6D010C01106D000D000F208D0142000D000F8D01010D000F20910146000D000F65010C011065000D000F2095014A000D000F9501010D000F2099014E000D000F5D010C01105D000D000F209D0152000D000F9D01010D000F20A10156000D000F55010C011055000D000F20A5015A000D000FA501010D000F20A9015E000D000F01020C011001000C031001000C051001000C071001000C091001000D000F2062D501000D000FD501010D000F2066D901000D000FCD01010C0110CD01000D000F206ADD01000D000FDD01010D000F206EE101000D000FC501010C0110C501000D000F2072E501000D000FE501010D000F2076E901000D000FBD01010C0110BD01000D000F207AED01000D000FED01010D000F207EF101000D000FB501010C0110B501000D000F208201F501000D000FF501010D000F208601F901000D000FAD01010C0110AD01000D000F208A01FD01000D000FFD01010D000F208E018102000D000F01020700082085029A0100070008850200090185808080088502010500169A0100170285808080089A01020500160102070008208902A6010007000889020009018580808008890201050016A6010017028580808008A601020500160102070008208D02B201000700088D0200090185808080088D0201050016B2010017028580808008B201020500160102070008209102BE010007000891020009018580808008910201050016BE010017028580808008BE0102050016
+ - Name: '__llvm_covfun (1)'
+ Type: SHT_PROGBITS
+ AddressAlign: 0x8
+ Content: FAD58DE7366495DB090000001800000000000000428729958077330401000001014F010402
+ - Name: __llvm_covmap
+ Type: SHT_PROGBITS
+ AddressAlign: 0x8
+ Content: 00000000210000000000000003000000011E001D2F746D702F6272616E63682D6C6F676963616C2D6D697865642E637070000000
+ - Name: __llvm_prf_names
+ Type: SHT_PROGBITS
+ AddressAlign: 0x1
+ Content: 0E005F5A3466756E636969016D61696E
+ - Type: SectionHeaderTable
+ Sections:
+ - Name: .strtab
+ - Name: __llvm_covfun
+ - Name: '__llvm_covfun (1)'
+ - Name: __llvm_covmap
+ - Name: __llvm_prf_names
+ - Name: .symtab
+Symbols:
+ - Name: __llvm_prf_names
+ Type: STT_SECTION
+ Section: __llvm_prf_names
+ - Name: __covrec_B30B5C302CEDA0F0u
+ Type: STT_OBJECT
+ Section: __llvm_covfun
+ Binding: STB_WEAK
+ Size: 0x3DC
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_DB956436E78DD5FAu
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (1)'
+ Binding: STB_WEAK
+ Size: 0x25
+ Other: [ STV_HIDDEN ]
+...
diff --git a/llvm/test/tools/llvm-cov/branch-macros.cpp b/llvm/test/tools/llvm-cov/Inputs/branch-macros.cpp
similarity index 70%
rename from llvm/test/tools/llvm-cov/branch-macros.cpp
rename to llvm/test/tools/llvm-cov/Inputs/branch-macros.cpp
index 73042ac397d406..712b2790f774aa 100644
--- a/llvm/test/tools/llvm-cov/branch-macros.cpp
+++ b/llvm/test/tools/llvm-cov/Inputs/branch-macros.cpp
@@ -1,6 +1,6 @@
-// RUN: llvm-profdata merge %S/Inputs/branch-macros.proftext -o %t.profdata
-// RUN: llvm-cov show --show-expansions --show-branches=count %S/Inputs/branch-macros.o32l -instr-profile %t.profdata -path-equivalence=/tmp,%S %s | FileCheck %s
-// RUN: llvm-cov report --show-branch-summary %S/Inputs/branch-macros.o32l -instr-profile %t.profdata -show-functions -path-equivalence=/tmp,%S %s | FileCheck %s -check-prefix=REPORT
+
+
+
#define COND1 (a == b)
#define COND2 (a != b)
@@ -50,11 +50,3 @@ int main(int argc, char *argv[])
__llvm_profile_write_file();
return 0;
}
-
-// REPORT: Name Regions Miss Cover Lines Miss Cover Branches Miss Cover
-// REPORT-NEXT: ---
-// REPORT-NEXT: _Z4funcii 28 4 85.71% 18 0 100.00% 30 14 53.33%
-// REPORT-NEXT: _Z5func2ii 13 1 92.31% 8 0 100.00% 10 2 80.00%
-// REPORT-NEXT: main 1 0 100.00% 6 0 100.00% 0 0 0.00%
-// REPORT-NEXT: ---
-// REPORT-NEXT: TOTAL 42 5 88.10% 32 0 100.00% 40 16 60.00%
diff --git a/llvm/test/tools/llvm-cov/Inputs/branch-macros.o32l b/llvm/test/tools/llvm-cov/Inputs/branch-macros.o32l
deleted file mode 100644
index bb4c85adeb4dbc25cc29d8aac06748a6dac3343d..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001
literal 4456
zcma)9Z)jWB6+ibqOSWWNmKDp696MGL+c+kEezN6%#ogq;UBDS_NrwpmRhFJ at wbq}>
z&zTEjGoy?QwtZSh)^=rscC6nFV{BgvNjloV@?p*x6c$(^g;pO1(HI+)(d>7w-j$w}
zX6&H%&N=s-^E>C<`|f>D-(6W-6+)0AK_gVxi1u5h#S at oogoa@~_-*1Jq}{}IuT1kN
zDk88}A^rN|?J_+$dvvd?iF;-5yf7CkByK}n?}HtZ7vuh*h$SjSw;|mt2WnaXTBxRl
zf)qV?k5h6j$kv8zZTHJGAto0qq+MUU3)y#czwA9HCYF%>E~K`Ksf&->DnUKbd%vuO
z4nIG5C}Qk?7uui86iWE2`umWJ&nWyN_e01)e=5_tw$<nQfT-Ps&x_lS{{6+HcecH&
zBdaXIPry$c!LOS4`-`_ApF27#YuZuSJ1tDkcMIBj->Q_n823lT1b2N4(os23(*n>!
zH7yi<XS<rQ>52JXmHB+g=haj$NEMUB$D$G>)ZtWy8qT4gP_<+3hC85Wu{N*V|HEJW
z{epS5^*6u9M8Df at m45YMcHrtC6S2e>-pw#OJVqU2W#!`23sZArG2!v}M0<Ou2!|u0
zzyFLF8am%4f{{+GO|(&G7lo;}PlGgwTj&Dc;(QaDpIQa^Daf}l-+H4f8d&QJbx<&R
z(aY><0z!1b&uoe!@R<uR8>7=S5RHYH>B7 at NJp%4MQBOBB&EsXo*UO47nmcG<o`Mu!
zM(Am==7T6M`-9XiuD0Ut253Jm0oo-%=h-?yh5>dYfGq*O%>eGu at URRG%h1SZJ at i$<
zu|E_t_$Pv+-EsYfjO&+iXC~@#Z_2p0Wt=-;Xj%pg$$;}uvBFDq*ni`zAMB=Iy8}5f
zbN-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^YQA7w#xq}kVQkk<rC+9$UC6o;)s8Av
z3b$}9TixT!QZ`s+Ue{Qyq547iKN6|4lD<6CakG=EHdvontCZTZFonfpHorxNT$xlR
zg9CS~p1iP`-LaD2DrIde$s!rMcF9g{fWMM+ at np`jQ?ek}a%55%8?=oHzQy=v;-URN
zDUOZjK8<wjIoq{&)wX>ecr5dNV~ST<?aup?Y2Vq`Za+R#6e(yMe$MumrV$*Ryr+h6
zaXpNOA-Yn<D}E0$)0?<>T-B`dexm_z7EbKPc-a0myax^Sy$u_maf(!Ze`~-?08G`#
zr?sk&&p-TX_5BAn&Z|yzRo~49yk}kY at jNIz2E(s5&rMJsLRX~f<2>&9TL&KZ!Ts{v
zL*ac284$Jl_`SsSsW*(O?*Yc#c!#d~`1?-b at j7(kQuHDgn(;U<zopoZuXk~AAM&7f
zIM0<Lj$vxV+jimcTk}bHcklpwA`z;$C*c)cc>E#zB)mfyxCccF?+pyN%BGLt$M1AS
z$}jHBt9mY5 at X*~*PT<P#1uP)r9XK}j8-c9e at XGHw__^2P_b{mEPxZmRKX1s(@4AG8
z%}n7n=4HPT*wvSV@@vd{2L_dwzbbhC*!Kg6tA5vkr!Ziu$&Gp0Zv=LJUo)wg#=IZF
zpz`w9ipu*<$nNzx0NyDEa!A>DFR*Mn<8Q$46-Q>qHoovT at fcngo)<T<4^s*kdM!!?
zH}<=z6maFYjCE^SdsI-Sf1wZFKSR!d@@s>iUiCX*(`WF*=fz`w^YFv3M*GNn2oT2M
L{|!7ZJWu}xjeK)v
diff --git a/llvm/test/tools/llvm-cov/Inputs/branch-macros.yaml b/llvm/test/tools/llvm-cov/Inputs/branch-macros.yaml
new file mode 100644
index 00000000000000..1b4e6bbfcbce5d
--- /dev/null
+++ b/llvm/test/tools/llvm-cov/Inputs/branch-macros.yaml
@@ -0,0 +1,61 @@
+--- !ELF
+FileHeader:
+ Class: ELFCLASS32
+ Data: ELFDATA2LSB
+ Type: ET_REL
+ Machine: EM_ARM
+ Flags: [ EF_ARM_EABI_VER5 ]
+ SectionHeaderStringTable: .strtab
+Sections:
+ - Name: '__llvm_covfun (1)'
+ Type: SHT_PROGBITS
+ AddressAlign: 0x8
+ Content: F0A0ED2C305C0BB3A8010000A9166572A6C7691F5CCB403140FE0666150000000000000000000000000000000000000000000F014545493D4135392D3101050509010D0D1101151519011D1D21012525291401101911020C010C0011140015001A1C020C001124020C00122C020C001234020C001201020A000B01000A001001000A001501000A001A204502000A000B45000F0010204906000F00103D0014001520410A00140015350019001A20390E0019001A2D001E001F203112001E001F0301050F001701000F0017200516000F00170205060F001720091A000F00170301070F001F3C00100015440019001E014C0910001501540A100016015C0B1000160301050F001701000F0017200D1E000F0017020D060F0017201122000F00170301070F001F64001000156C0019001E017409100015017C0A1000160301050F001701000F0017201526000F00170215060F001720192A000F00170301070F001F8401001000158C010019001E019401091000150301050F001701000F0017201D2E000F0017021D060F0017202132000F00170301070F001F9C0100100015A4010019001E0301050F001701000F0017202536000F00170225060F001720293A000F0017
+ - Name: __llvm_covfun
+ Type: SHT_PROGBITS
+ AddressAlign: 0x8
+ Content: B01D983FC6736395C8000000403729A19E990E4D5CCB403140FE06660D0000000000000000000000000006050905150519191D010D0D110301241A07020C010E0014140018001D011C0B1000160505080F0026200209000F002624001000152C0018001D3400200025013C0A1000160305070F001F44001000154C0019001E0115060F00170106050F00170154091000150305050F001705000F001720190A000F00170219060F0017201D0E000F00170401070F001F01000F001F5C00100015640019001E0301050F001701000F0017200D12000F0017020D060F0017201116000F0017
+ - Name: '__llvm_covfun (2)'
+ Type: SHT_PROGBITS
+ AddressAlign: 0x8
+ Content: FAD58DE7366495DB0900000018000000000000005CCB403140FE066601000001012F010502
+ - Name: __llvm_covmap
+ Type: SHT_PROGBITS
+ AddressAlign: 0x8
+ Content: 000000001A0000000000000003000000011700162F746D702F6272616E63682D6D6163726F732E6370700000
+ - Name: __llvm_prf_names
+ Type: SHT_PROGBITS
+ AddressAlign: 0x1
+ Content: 19005F5A3466756E636969015F5A3566756E63326969016D61696E
+ - Type: SectionHeaderTable
+ Sections:
+ - Name: .strtab
+ - Name: '__llvm_covfun (1)'
+ - Name: __llvm_covfun
+ - Name: '__llvm_covfun (2)'
+ - Name: __llvm_covmap
+ - Name: __llvm_prf_names
+ - Name: .symtab
+Symbols:
+ - Name: __llvm_prf_names
+ Type: STT_SECTION
+ Section: __llvm_prf_names
+ - Name: __covrec_956373C63F981DB0u
+ Type: STT_OBJECT
+ Section: __llvm_covfun
+ Binding: STB_WEAK
+ Size: 0xE4
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_B30B5C302CEDA0F0u
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (1)'
+ Binding: STB_WEAK
+ Size: 0x1C4
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_DB956436E78DD5FAu
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (2)'
+ Binding: STB_WEAK
+ Size: 0x25
+ Other: [ STV_HIDDEN ]
+...
diff --git a/llvm/test/tools/llvm-cov/Inputs/branch-showBranchPercentage.c b/llvm/test/tools/llvm-cov/Inputs/branch-showBranchPercentage.c
new file mode 100644
index 00000000000000..c41739ff0b22f1
--- /dev/null
+++ b/llvm/test/tools/llvm-cov/Inputs/branch-showBranchPercentage.c
@@ -0,0 +1,58 @@
+
+
+
+
+
+#include <stdio.h>
+#include <stdlib.h>
+
+extern void __llvm_profile_write_file(void);
+
+int main(int argc, char *argv[])
+{
+ int i = 0;
+ if (argc < 3) // CHECK: Branch ([[@LINE]]:7): [True: 16.67%, False: 83.33%]
+ {
+ __llvm_profile_write_file();
+ return 0;
+ }
+
+ int a = atoi(argv[1]);
+ int b = atoi(argv[2]);
+
+ // CHECK: Branch ([[@LINE+4]]:8): [True: 20.00%, False: 80.00%]
+ // CHECK: Branch ([[@LINE+3]]:18): [True: 0.00%, False: 100.00%]
+ // CHECK: Branch ([[@LINE+2]]:29): [True: 0.00%, False: 100.00%]
+ // CHECK: Branch ([[@LINE+1]]:40): [True: 40.00%, False: 60.00%]
+ if ((a == 0 && b == 2) || b == 34 || a == b)
+ printf("case1\n");
+
+ b = (a != 0 || a == 2) ? b : b+2; // CHECK: Branch ([[@LINE]]:8): [True: 80.00%, False: 20.00%]
+ // CHECK: Branch ([[@LINE-1]]:18): [True: 0.00%, False: 100.00%]
+ b = (a != 0 && a == 1); // CHECK: Branch ([[@LINE]]:8): [True: 80.00%, False: 20.00%]
+ // CHECK: Branch ([[@LINE-1]]:18): [True: 25.00%, False: 75.00%]
+ for (i = 0; i < b; i++) { a = 2 + b + b; }
+ // CHECK: Branch ([[@LINE-1]]:15): [True: 16.67%, False: 83.33%]
+
+ b = a;
+
+ switch (a)
+ {
+ case 0: // CHECK: Branch ([[@LINE]]:5): [True: 20.00%, False: 80.00%]
+ printf("case0\n");
+ case 2: // CHECK: Branch ([[@LINE]]:5): [True: 20.00%, False: 80.00%]
+ printf("case2\n");
+ case 3: // CHECK: Branch ([[@LINE]]:5): [True: 0.00%, False: 100.00%]
+ printf("case3\n");
+ default: break; // CHECK: Branch ([[@LINE]]:5): [True: 60.00%, False: 40.00%]
+ }
+
+ i = 0;
+ do {
+ printf("loop\n");
+ } while (i++ < 10); // CHECK: Branch ([[@LINE]]:12): [True: 90.91%, False: 9.09%]
+
+ __llvm_profile_write_file();
+
+ return b;
+}
diff --git a/llvm/test/tools/llvm-cov/Inputs/branch-showBranchPercentage.o32l b/llvm/test/tools/llvm-cov/Inputs/branch-showBranchPercentage.o32l
deleted file mode 100644
index 5f8b9fa10582777140f099297ecccc2374a4c0d5..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001
literal 3284
zcmdT`Z)jxI6+idBnaL!ZOp=LNlQmi1X0su&$(xx>GLsat-N`2D1~!^V#rBKio0qqf
zshN4h%*$?+LWA8xl`V)Oi1mv_WRYT_A}AsXLQqy^{m?;ZD?$-F-<l#=T5$V2Z{D4K
z`l0yMlf3&o=iJ{p_uRk9FIO+F2_Z;{ph>!I5nb!_dct!aOwu5FtFN8=7e(H|*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-showBranchPercentage.yaml
new file mode 100644
index 00000000000000..f64ad06e46bbd2
--- /dev/null
+++ b/llvm/test/tools/llvm-cov/Inputs/branch-showBranchPercentage.yaml
@@ -0,0 +1,39 @@
+--- !ELF
+FileHeader:
+ Class: ELFCLASS32
+ Data: ELFDATA2LSB
+ Type: ET_REL
+ Machine: EM_ARM
+ Flags: [ EF_ARM_EABI_VER5 ]
+ SectionHeaderStringTable: .strtab
+Sections:
+ - Name: __llvm_covfun
+ Type: SHT_PROGBITS
+ AddressAlign: 0x8
+ Content: FAD58DE7366495DB70010000776050A22C20FE35CDAF69BBDD37045201001C0105021D1D2115190D110229292D0225023131352F050139374D45494145434D414967494145674D4145634D67494145674941453D513D5132010C012E02010207000F2005020007000F0500100183808080080501030304020304028380808008020203260202070700190200070024020007002E020008000E201D060008000E1D0012001820210A0012001815001D0024200E19001D00240D0028002E2012110028002E09002F0185808080080901050016020208000E2016290008000E2900120018201A2D0012001825001A009C8080800825001C001D1E00200023020208000E2031220008000E3100120018203526001200182A020F0014203902000F0014390016001939001A009B8080800839001B002D00060307938080800841010506132041330005000B670205041320453F0005000B630205021320494F0005000B5702050013204D630005000C3D00130383808080083D030308026F010602046F020C001420513D000C0014
+ - Name: __llvm_covmap
+ Type: SHT_PROGBITS
+ AddressAlign: 0x8
+ Content: 00000000260000000000000003000000012300222F746D702F6272616E63682D73686F774272616E636850657263656E746167652E630000
+ - Name: __llvm_prf_names
+ Type: SHT_PROGBITS
+ AddressAlign: 0x1
+ Content: 04006D61696E
+ - Type: SectionHeaderTable
+ Sections:
+ - Name: .strtab
+ - Name: __llvm_covfun
+ - Name: __llvm_covmap
+ - Name: __llvm_prf_names
+ - Name: .symtab
+Symbols:
+ - Name: __llvm_prf_names
+ Type: STT_SECTION
+ Section: __llvm_prf_names
+ - Name: __covrec_DB956436E78DD5FAu
+ Type: STT_OBJECT
+ Section: __llvm_covfun
+ Binding: STB_WEAK
+ Size: 0x18C
+ Other: [ STV_HIDDEN ]
+...
diff --git a/llvm/test/tools/llvm-cov/Inputs/branch-templates.cpp b/llvm/test/tools/llvm-cov/Inputs/branch-templates.cpp
new file mode 100644
index 00000000000000..0795a5346380de
--- /dev/null
+++ b/llvm/test/tools/llvm-cov/Inputs/branch-templates.cpp
@@ -0,0 +1,38 @@
+
+
+
+
+
+#include <stdio.h>
+template<typename T>
+void unused(T x) {
+ return;
+}
+
+template<typename T>
+int func(T x) {
+ if(x) // CHECK: | Branch ([[@LINE]]:6): [True: 0, False: 1]
+ return 0; // CHECK: | Branch ([[@LINE-1]]:6): [True: 1, False: 0]
+ else // CHECK: | Branch ([[@LINE-2]]:6): [True: 0, False: 1]
+ return 1;
+ int j = 1;
+}
+
+ // CHECK-LABEL: _Z4funcIiEiT_:
+ // CHECK: | | Branch ([[@LINE-8]]:6): [True: 0, False: 1]
+ // CHECK-LABEL: _Z4funcIbEiT_:
+ // CHECK: | | Branch ([[@LINE-10]]:6): [True: 1, False: 0]
+ // CHECK-LABEL: _Z4funcIfEiT_:
+ // CHECK: | | Branch ([[@LINE-12]]:6): [True: 0, False: 1]
+
+extern "C" { extern void __llvm_profile_write_file(void); }
+int main() {
+ if (func<int>(0)) // CHECK: | Branch ([[@LINE]]:7): [True: 1, False: 0]
+ printf("case1\n");
+ if (func<bool>(true)) // CHECK: | Branch ([[@LINE]]:7): [True: 0, False: 1]
+ printf("case2\n");
+ if (func<float>(0.0)) // CHECK: | Branch ([[@LINE]]:7): [True: 1, False: 0]
+ printf("case3\n");
+ __llvm_profile_write_file();
+ return 0;
+}
diff --git a/llvm/test/tools/llvm-cov/Inputs/branch-templates.o32l b/llvm/test/tools/llvm-cov/Inputs/branch-templates.o32l
deleted file mode 100644
index d611727170d9b6bc452efdb8a6c725061e3e0419..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001
literal 5408
zcmcInYit}>6+U;?>)6KYIJQ$iVmq5Bj*Dj>UcV}}@;Y{!fQy<cNC6dA`xx8Xcpt3C
z!I3Iz3P=UfDh&n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$t2=PTe=Sq_b33wFdvU|
zoo at rWzmHG&`k<dUasU(M at 1qOGUVUuW^>G<RbsxM_>AHUb4k^k{d*kE%g5x8GL>%ee
zx_nCj5yw7wH`Dnxp!@rn_Vt0!hJz#aS+}k<dUfYfmv;zFo?E_ASGSC!x(}U?<GAAH
z+v$V*fPP{~x{t-WeCq%a$3D1j_Uq#k`p`JuHHjnt0gO`a#Q@?ujBB(#;xnWTuzy}2
z_vPaqcE5b>81DiTc(h->oG%~$Tke-{?H=<j`|{~|*{k2%`{cWYF*x($jr%;-t$&^B
zKK_O{b-n-BpoG0=C^YUzNXC5Ybb^Q*g48!wje7|o|2gyw0(!lKfoBiIZh-yo!}j&d
zYZY<i-yk3H0rW|F5p|hQ6Jw<Md`}`DuU}kOgJ7L+rw?DgA;eFBNjl$7A0F;|2<Sde
z0k>Zt&-nV_HBi_6Ir1>K?&I})?Blwx58l;vzWP3xkA09ytVOEtV*>%*$1vji_3?dQ
zAH25ey2-je{(g^ryyEMF{|R-z`aYPCJ&b@!`}OgvuMhrL)O|b;o$FLn4+2qbK<b!@
zI at IG{>^yMZb=~nWMqcrx&T$Di|M{YE2`JPx{f-0jk&b- at K9nx&5OEi at 0jY5>Kxvxa
yF6q#p&@a~$*E31u9)}WeaqINI4jj+idfc~w^OiDU at -w^-o^8y-eaPW*UHlL0cE2A0
diff --git a/llvm/test/tools/llvm-cov/Inputs/branch-templates.yaml b/llvm/test/tools/llvm-cov/Inputs/branch-templates.yaml
new file mode 100644
index 00000000000000..671c530e939e88
--- /dev/null
+++ b/llvm/test/tools/llvm-cov/Inputs/branch-templates.yaml
@@ -0,0 +1,72 @@
+--- !ELF
+FileHeader:
+ Class: ELFCLASS32
+ Data: ELFDATA2LSB
+ Type: ET_REL
+ Machine: EM_ARM
+ Flags: [ EF_ARM_EABI_VER5 ]
+ SectionHeaderStringTable: .strtab
+Sections:
+ - Name: '__llvm_covfun (3)'
+ Type: SHT_PROGBITS
+ AddressAlign: 0x8
+ Content: FAD58DE7366495DB5D00000058242991A4449202DDC07F26680C05B801000301050109010D0D011D0C0902010107001320050200070013050014018580808008050105001601010700172009060007001709001801858080800809010500160101070017200D0A000700170D00180185808080080D01050016
+ - Name: '__llvm_covfun (1)'
+ Type: SHT_PROGBITS
+ AddressAlign: 0x8
+ Content: 5427717259E0E43E4A0000001136619202000000DDC07F26680C05B801000101050A010D0F0602010106000720050200060007050008018580808008050105000D02000D008E8080800802000E028580808008020205000D00000D0183808080080001030102
+ - Name: '__llvm_covfun (2)'
+ Type: SHT_PROGBITS
+ AddressAlign: 0x8
+ Content: 4B7E22082F0551AA4A0000001136619202000000DDC07F26680C05B801000101050A010D0F0602010106000720050200060007050008018580808008050105000D02000D008E8080800802000E028580808008020205000D00000D0183808080080001030102
+ - Name: __llvm_covfun
+ Type: SHT_PROGBITS
+ AddressAlign: 0x8
+ Content: AC1440BC3DA3E41A4A0000001136619202000000DDC07F26680C05B801000101050A010D0F0602010106000720050200060007050008018580808008050105000D02000D008E8080800802000E028580808008020205000D00000D0183808080080001030102
+ - Name: __llvm_covmap
+ Type: SHT_PROGBITS
+ AddressAlign: 0x8
+ Content: 000000001D0000000000000003000000011A00192F746D702F6272616E63682D74656D706C617465732E637070000000
+ - Name: __llvm_prf_names
+ Type: SHT_PROGBITS
+ AddressAlign: 0x1
+ Content: 2E006D61696E015F5A3466756E6349694569545F015F5A3466756E6349624569545F015F5A3466756E6349664569545F
+ - Type: SectionHeaderTable
+ Sections:
+ - Name: .strtab
+ - Name: '__llvm_covfun (3)'
+ - Name: '__llvm_covfun (1)'
+ - Name: '__llvm_covfun (2)'
+ - Name: __llvm_covfun
+ - Name: __llvm_covmap
+ - Name: __llvm_prf_names
+ - Name: .symtab
+Symbols:
+ - Name: __llvm_prf_names
+ Type: STT_SECTION
+ Section: __llvm_prf_names
+ - Name: __covrec_1AE4A33DBC4014ACu
+ Type: STT_OBJECT
+ Section: __llvm_covfun
+ Binding: STB_WEAK
+ Size: 0x66
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_3EE4E05972712754u
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (1)'
+ Binding: STB_WEAK
+ Size: 0x66
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_AA51052F08227E4Bu
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (2)'
+ Binding: STB_WEAK
+ Size: 0x66
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_DB956436E78DD5FAu
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (3)'
+ Binding: STB_WEAK
+ Size: 0x79
+ Other: [ STV_HIDDEN ]
+...
diff --git a/llvm/test/tools/llvm-cov/Inputs/mcdc-const-folding.o b/llvm/test/tools/llvm-cov/Inputs/mcdc-const-folding.o
deleted file mode 100644
index 7a16162f29c00777d9a05f5fed1cc4cbf333c56c..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001
literal 34528
zcmcg#3wTu3wLWJKkD!DEMU547qEgc;IFm^xGiq at rnTgS&V)22`5E5PjNeY2R>mw at I
zP+!y*rS*kxP}G20u~%DK(PC?_Tx%`8-g`@Xy)CV^#cMx`)$elG+GnlV`|PuK9?U2E
z`%czg|6Y5owg0`(Is2TMf$Q^A8zZjkIaFL{isQ1P$erg&B_paC=WVcT+BY1vo>Khl
z#<#pez>0lc2UB&U`+g+;dY}8&&Jtk at Ml1JzRMsJsIc3XUpHue9k3TBAUg(?LjV|;Z
z#eE}h{l4Td^bLKa>+!bk8zUHNlUwLTeJH;^SIKW!{Pp)`9GM>&+4I{NS+Q?vp_i*f
zQu9OCpR?wu_6p`VX#PH?e%$>-cj>V~D6 at P|S1Cb#?ndwZVH+dyElR%B7Jq#+(hHo|
z+7c$q!Fn8!Yd64kFm0UwK3D<za5j2<E+nwDu&7`#`Xq0{l`{gD+WUzC#xfXpEB16n
zS2EE(!0@<Ws{UG&V^Jn=Pk)PFBYsa;Eg>sE#wZg>vyDJZX1`Mj9&Me;cV_v%K`joT
z0GIO7)NLb7!M>&Cq%j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ml b/llvm/test/tools/llvm-cov/Inputs/mcdc-const-folding.yaml
new file mode 100644
index 00000000000000..18dc57488acb30
--- /dev/null
+++ b/llvm/test/tools/llvm-cov/Inputs/mcdc-const-folding.yaml
@@ -0,0 +1,333 @@
+--- !ELF
+FileHeader:
+ Class: ELFCLASS64
+ Data: ELFDATA2LSB
+ OSABI: ELFOSABI_GNU
+ Type: ET_REL
+ Machine: EM_X86_64
+ SectionHeaderStringTable: .strtab
+Sections:
+ - Name: __llvm_covfun
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: AA19D25F7410F1EA300000000E06000000000000B975BFDE464C3C13010101050906010314020201010C000D280302000C0012300000010200000C000D050011001230090202000000110012
+ - Name: '__llvm_covfun (1)'
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: 92691AC8D7253F8B300000000E06000000000000B975BFDE464C3C13010101010506010614020201010C000D280302000C0012300502010200000C000D050011001230000002000000110012
+ - Name: '__llvm_covfun (2)'
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: 9A7D6FA40D389A5B300000000E06000000000000B975BFDE464C3C13010101050906010914020201010C000D280302000C0012300000010200000C000D050011001230090202000000110012
+ - Name: '__llvm_covfun (3)'
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: 3CC016E1B5A95933300000000E06000000000000B975BFDE464C3C13010101010506010C14020201010C000D280302000C0012300502010200000C000D050011001230000002000000110012
+ - Name: '__llvm_covfun (4)'
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: 98207F8F78271E50300000000F06000000000000B975BFDE464C3C13010101050906010F14020201010C000D280302000C0012300000010002000C000D050011001230020902000000110012
+ - Name: '__llvm_covfun (5)'
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: 0969FC47730492F1300000000F06000000000000B975BFDE464C3C13010101010506011214020201010C000D280302000C0012300205010002000C000D050011001230000002000000110012
+ - Name: '__llvm_covfun (6)'
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: 0ECB0EF7963F6F79300000000F06000000000000B975BFDE464C3C13010101050906011514020201010C000D280302000C0012300000010002000C000D050011001230020902000000110012
+ - Name: '__llvm_covfun (7)'
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: 123E012CB073B24A300000000F06000000000000B975BFDE464C3C13010101010506011814020201010C000D280302000C0012300205010002000C000D050011001230000002000000110012
+ - Name: '__llvm_covfun (8)'
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: C2EA1D70E059B55D460000008E83010000000000B975BFDE464C3C130101020D11050909011C1C020201010C000D01000C0012280403000C0017300000010300000C000D0D0011001230110203020000110012050016001730090602000000160017
+ - Name: '__llvm_covfun (9)'
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: 24244E16CFFB9F53460000008E83010000000000B975BFDE464C3C13010102010D050909011F1C020201010C000D01000C0012280403000C0017300D02010300000C000D0D0011001230000003020000110012050016001730090602000000160017
+ - Name: '__llvm_covfun (10)'
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: CC9CCD1D2ED1627D460000008E83010000000000B975BFDE464C3C130101020D1105090901221C020201010C000D01000C0012280403000C0017300000010300000C000D0D0011001230110203020000110012050016001730090602000000160017
+ - Name: '__llvm_covfun (11)'
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: 69198FBDA5C488EE460000008E83010000000000B975BFDE464C3C13010102010D05090901251C020201010C000D01000C0012280403000C0017300D02010300000C000D0D0011001230000003020000110012050016001730090602000000160017
+ - Name: '__llvm_covfun (12)'
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: A753680B241373ED46000000CF83010000000000B975BFDE464C3C130101020D1105090901281C020201010C000D01000C0012280403000C0017300000010003000C000D0D0011001230021103000200110012050016001730060902000000160017
+ - Name: '__llvm_covfun (13)'
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: 54BD46601EA033AC46000000CF83010000000000B975BFDE464C3C13010102010D050909012B1C020201010C000D01000C0012280403000C001730020D010003000C000D0D0011001230000003000200110012050016001730060902000000160017
+ - Name: '__llvm_covfun (14)'
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: 39953E03B6ADA13B46000000CF83010000000000B975BFDE464C3C130101020D11050909012E1C020201010C000D01000C0012280403000C0017300000010003000C000D0D0011001230021103000200110012050016001730060902000000160017
+ - Name: '__llvm_covfun (15)'
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: 9BCFA8D8AA6B9E2046000000CF83010000000000B975BFDE464C3C13010102010D05090901311C020201010C000D01000C0012280403000C001730020D010003000C000D0D0011001230000003000200110012050016001730060902000000160017
+ - Name: '__llvm_covfun (16)'
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: 4F2882F8142D1DD9460000008E83010000000000B975BFDE464C3C13010102010D0D110901351C020201010C000D01000C0012280403000C0017300D02010300000C000D0D0011001230110603020000110012050016001730000002000000160017
+ - Name: '__llvm_covfun (17)'
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: 98DB88AFB7497C76460000008E83010000000000B975BFDE464C3C13010102010D05090901381C020201010C000D01000C0012280403000C0017300D02010300000C000D0D0011001230000003020000110012050016001730090602000000160017
+ - Name: '__llvm_covfun (18)'
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: 596357935D55EEBA460000008E83010000000000B975BFDE464C3C13010102010D0D1109013B1C020201010C000D01000C0012280403000C0017300D02010300000C000D0D0011001230110603020000110012050016001730000002000000160017
+ - Name: '__llvm_covfun (19)'
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: 3237FBD998D0D824460000008E83010000000000B975BFDE464C3C13010102010D050909013E1C020201010C000D01000C0012280403000C0017300D02010300000C000D0D0011001230000003020000110012050016001730090602000000160017
+ - Name: '__llvm_covfun (20)'
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: D656F1340A0C4ED846000000CF83010000000000B975BFDE464C3C13010102010D0D110901411C020201010C000D01000C0012280403000C001730020D010003000C000D0D0011001230061103000200110012050016001730000002000000160017
+ - Name: '__llvm_covfun (21)'
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: 5E66CCF22EE6A4AC46000000CF83010000000000B975BFDE464C3C13010102010D05090901441C020201010C000D01000C0012280403000C001730020D010003000C000D0D0011001230000003000200110012050016001730060902000000160017
+ - Name: '__llvm_covfun (22)'
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: 7C4DEA109976A2E846000000CF83010000000000B975BFDE464C3C13010102010D0D110901471C020201010C000D01000C0012280403000C001730020D010003000C000D0D0011001230061103000200110012050016001730000002000000160017
+ - Name: '__llvm_covfun (23)'
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: E25997DF8D6D856B46000000CF83010000000000B975BFDE464C3C13010102010D050909014A1C020201010C000D01000C0012280403000C001730020D010003000C000D0D0011001230000003000200110012050016001730060902000000160017
+ - Name: '__llvm_covfun (24)'
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: FAD58DE7366495DB1D0000001800000000000000B975BFDE464C3C1301010005014F0121021004010001100901000110090100011009010001
+ - Name: __llvm_covmap
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: 000000001B000000000000000600000002180000166D6364632D636F6E73742D666F6C64696E672E63707000
+ - Name: __llvm_prf_names
+ Type: SHT_PROGBITS
+ Flags: [ SHF_ALLOC, SHF_GNU_RETAIN ]
+ AddressAlign: 0x1
+ Content: 8402005F5A35636173653062015F5A35636173653162015F5A35636173653262015F5A35636173653362015F5A35636173653462015F5A35636173653562015F5A35636173653662015F5A35636173653762015F5A3563617365386262015F5A3563617365396262015F5A3563617365616262015F5A3563617365626262015F5A3563617365636262015F5A3563617365646262015F5A3563617365656262015F5A3563617365666262015F5A3563617365676262015F5A3563617365686262015F5A3563617365696262015F5A35636173656A6262015F5A35636173656B6262015F5A35636173656C6262015F5A35636173656D6262015F5A35636173656E6262016D61696E
+ - Type: SectionHeaderTable
+ Sections:
+ - Name: .strtab
+ - Name: __llvm_covfun
+ - Name: '__llvm_covfun (1)'
+ - Name: '__llvm_covfun (2)'
+ - Name: '__llvm_covfun (3)'
+ - Name: '__llvm_covfun (4)'
+ - Name: '__llvm_covfun (5)'
+ - Name: '__llvm_covfun (6)'
+ - Name: '__llvm_covfun (7)'
+ - Name: '__llvm_covfun (8)'
+ - Name: '__llvm_covfun (9)'
+ - Name: '__llvm_covfun (10)'
+ - Name: '__llvm_covfun (11)'
+ - Name: '__llvm_covfun (12)'
+ - Name: '__llvm_covfun (13)'
+ - Name: '__llvm_covfun (14)'
+ - Name: '__llvm_covfun (15)'
+ - Name: '__llvm_covfun (16)'
+ - Name: '__llvm_covfun (17)'
+ - Name: '__llvm_covfun (18)'
+ - Name: '__llvm_covfun (19)'
+ - Name: '__llvm_covfun (20)'
+ - Name: '__llvm_covfun (21)'
+ - Name: '__llvm_covfun (22)'
+ - Name: '__llvm_covfun (23)'
+ - Name: '__llvm_covfun (24)'
+ - Name: __llvm_covmap
+ - Name: __llvm_prf_names
+ - Name: .symtab
+Symbols:
+ - Name: __llvm_covmap
+ Type: STT_SECTION
+ Section: __llvm_covmap
+ - Name: __llvm_prf_names
+ Type: STT_SECTION
+ Section: __llvm_prf_names
+ - Name: __covrec_EAF110745FD219AAu
+ Type: STT_OBJECT
+ Section: __llvm_covfun
+ Binding: STB_WEAK
+ Size: 0x4C
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_8B3F25D7C81A6992u
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (1)'
+ Binding: STB_WEAK
+ Size: 0x4C
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_5B9A380DA46F7D9Au
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (2)'
+ Binding: STB_WEAK
+ Size: 0x4C
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_3359A9B5E116C03Cu
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (3)'
+ Binding: STB_WEAK
+ Size: 0x4C
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_501E27788F7F2098u
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (4)'
+ Binding: STB_WEAK
+ Size: 0x4C
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_F192047347FC6909u
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (5)'
+ Binding: STB_WEAK
+ Size: 0x4C
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_796F3F96F70ECB0Eu
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (6)'
+ Binding: STB_WEAK
+ Size: 0x4C
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_4AB273B02C013E12u
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (7)'
+ Binding: STB_WEAK
+ Size: 0x4C
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_5DB559E0701DEAC2u
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (8)'
+ Binding: STB_WEAK
+ Size: 0x62
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_539FFBCF164E2424u
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (9)'
+ Binding: STB_WEAK
+ Size: 0x62
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_7D62D12E1DCD9CCCu
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (10)'
+ Binding: STB_WEAK
+ Size: 0x62
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_EE88C4A5BD8F1969u
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (11)'
+ Binding: STB_WEAK
+ Size: 0x62
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_ED7313240B6853A7u
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (12)'
+ Binding: STB_WEAK
+ Size: 0x62
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_AC33A01E6046BD54u
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (13)'
+ Binding: STB_WEAK
+ Size: 0x62
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_3BA1ADB6033E9539u
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (14)'
+ Binding: STB_WEAK
+ Size: 0x62
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_209E6BAAD8A8CF9Bu
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (15)'
+ Binding: STB_WEAK
+ Size: 0x62
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_D91D2D14F882284Fu
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (16)'
+ Binding: STB_WEAK
+ Size: 0x62
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_767C49B7AF88DB98u
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (17)'
+ Binding: STB_WEAK
+ Size: 0x62
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_BAEE555D93576359u
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (18)'
+ Binding: STB_WEAK
+ Size: 0x62
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_24D8D098D9FB3732u
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (19)'
+ Binding: STB_WEAK
+ Size: 0x62
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_D84E0C0A34F156D6u
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (20)'
+ Binding: STB_WEAK
+ Size: 0x62
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_ACA4E62EF2CC665Eu
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (21)'
+ Binding: STB_WEAK
+ Size: 0x62
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_E8A2769910EA4D7Cu
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (22)'
+ Binding: STB_WEAK
+ Size: 0x62
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_6B856D8DDF9759E2u
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (23)'
+ Binding: STB_WEAK
+ Size: 0x62
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_DB956436E78DD5FAu
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (24)'
+ Binding: STB_WEAK
+ Size: 0x39
+ Other: [ STV_HIDDEN ]
+...
diff --git a/llvm/test/tools/llvm-cov/Inputs/mcdc-const.o b/llvm/test/tools/llvm-cov/Inputs/mcdc-const.o
deleted file mode 100644
index bc38b71b5de072cedeb2172d160d6705d4855c47..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001
literal 5208
zcmb_fU1(fY5T0{yHb4EzZW>eVuNx>*)ZA`jn<mAdZJNXtLk)^372R%jH$RyDVfQAj
zKG>+#Kd7kCHwCFa2)+m+D1x;1L8=c$sG=y?hl14?s|5us#+h?x?mao~Qm_u}ojKpk
zoS8Fc&bfDwj7^L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000000..5e57a7e7739d6d
--- /dev/null
+++ b/llvm/test/tools/llvm-cov/Inputs/mcdc-const.yaml
@@ -0,0 +1,57 @@
+--- !ELF
+FileHeader:
+ Class: ELFCLASS64
+ Data: ELFDATA2LSB
+ OSABI: ELFOSABI_GNU
+ Type: ET_REL
+ Machine: EM_X86_64
+ SectionHeaderStringTable: .strtab
+Sections:
+ - Name: __llvm_covfun
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: 8AC9CB6DFFBEFE928600000091E438CFA3000000A8826E3AB548EA6F01010201151D2113010A2B04021001010001010107000F010007001B0100070020280B050007002001000800093015020104030008000915000D000E300000040003000D000E110013001B1100140015300000030502001400151D0019001A3021060500020019001A09001F0020300000020000001F00200500210185808080080501050024
+ - Name: '__llvm_covfun (1)'
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: FAD58DE7366495DB130000001800000000000000A8826E3AB548EA6F01010003011101090210050100011002010001
+ - Name: __llvm_covmap
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: 00000000130000000000000006000000021000000E6D6364632D636F6E73742E63707000
+ - Name: __llvm_prf_names
+ Type: SHT_PROGBITS
+ Flags: [ SHF_ALLOC, SHF_GNU_RETAIN ]
+ AddressAlign: 0x1
+ Content: 10005F5A347465737462626262016D61696E
+ - Type: SectionHeaderTable
+ Sections:
+ - Name: .strtab
+ - Name: __llvm_covfun
+ - Name: '__llvm_covfun (1)'
+ - Name: __llvm_covmap
+ - Name: __llvm_prf_names
+ - Name: .symtab
+Symbols:
+ - Name: __llvm_covmap
+ Type: STT_SECTION
+ Section: __llvm_covmap
+ - Name: __llvm_prf_names
+ Type: STT_SECTION
+ Section: __llvm_prf_names
+ - Name: __covrec_92FEBEFF6DCBC98Au
+ Type: STT_OBJECT
+ Section: __llvm_covfun
+ Binding: STB_WEAK
+ Size: 0xA2
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_DB956436E78DD5FAu
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (1)'
+ Binding: STB_WEAK
+ Size: 0x2F
+ Other: [ STV_HIDDEN ]
+...
diff --git a/llvm/test/tools/llvm-cov/Inputs/mcdc-general-18.o b/llvm/test/tools/llvm-cov/Inputs/mcdc-general-18.o
deleted file mode 100644
index e802f51132c068f0f4e2921c952710cb5c5665e5..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001
literal 6456
zcmd5=eQaA-6~FJjWU*VvcC)5U(xq}rH?p!k>?X~c(jYsHvs7eLwzAQ|z;zubjTV2%
zd5H!L7F4%e5a~8hCH_Df|1qH<O`6nwfJVE*v<UIB!ZxHz2nkdgBG9IyG8ojHbKg0B
z*Ecr%gMT=ZeeU_)^Zm}dzR6?Bi80eKEJ0+5PYQztg}=1L6XJ3i7dt`o{={bz4;-0X
z{&`~go$*RD?krzREZ>N&o~k&z2nn6Lm{<v%E}wV8gp9AWqw4y><u?dPgwDOQ5 at _>Z
zC|`2!B`h8~_tr|&n}B?okPBBWG95Qwd)~P8d!JeLIE)^z;#c{y(@$`+Tyb`+r=+UP
zu6#LEehzeKf2kD>%(d^rx4SlCt6&s5^&LRgc0w<_nDKK){L+=UZy=0b{s0Ob+^yVo
z;H!qd?i`^tRPs}3!C1Wfmr(fy&(O<@J*{|U5VU?<HL<lbUYfM~GCnPE>nySdHy7yV
z>nnjI)|@O~caG97wB~MFHi|ud at +ZE}CBBeIeSQs$xhw0NHt5UH3R<<hILW!3lsz}E
zg$i;p9r}&r*Fuj;PHJv_ek!vDw0?~B#jd}COa_!sSfa1WtxK_036Yr>YH`(dXikSd
zxIn%+Fo~WU&3~*SolBJb$Id@^5hev&0)(NFzP|diT;<gp-#iAu-(NrQ^q;SdKC!;v
z{%B at b?puZtFj`x;_}kk%jh>!cyZicL#_(`rD49GQH8y>0vl%uFVHie>2pOV9?C2Fu
z$PD2V{%EUdS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yx0Ja35Dn-KXlK)eI?+=n*>i__H?x=Ty<~L58XovSsJ^p_HjJhJT
diff --git a/llvm/test/tools/llvm-cov/Inputs/mcdc-general-18.yaml b/llvm/test/tools/llvm-cov/Inputs/mcdc-general-18.yaml
new file mode 100644
index 00000000000000..13a9bce74ab1a2
--- /dev/null
+++ b/llvm/test/tools/llvm-cov/Inputs/mcdc-general-18.yaml
@@ -0,0 +1,57 @@
+--- !ELF
+FileHeader:
+ Class: ELFCLASS64
+ Data: ELFDATA2LSB
+ OSABI: ELFOSABI_GNU
+ Type: ET_REL
+ Machine: EM_X86_64
+ SectionHeaderStringTable: .strtab
+Sections:
+ - Name: __llvm_covfun
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: 8AC9CB6DFFBEFE9260010000F7C63A91EAF34488EB382E2763226D9301010C010D0D1109151519012121251D2D2D31013D3D413945454930010A2B0B021001010001010107000F010007001B2800040007001B0100080009300D02010302000800090D000D000E301106030002000D000E090013001B090014001530150A02040000140015150019001A30190E0400000019001A05001C018580808008050105002410010100010101070008010007000D2802020007000D3021120102000007000821000C000D302516020000000C000D1D000E008F808080081D000F01241D001300141D0013001928030200130019302D1A010200001300142D0018001930311E0200000018001929001A01858080800829010500241001010001010107000F010007010F2804040007010F0100080009303D22010300000800093D000D000E304126030200000D000E390107000F390008000930452A0204000008000945000D000E30492E040000000D000E3500100185808080083501050024
+ - Name: '__llvm_covfun (1)'
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: FAD58DE7366495DB130000001800000000000000EB382E2763226D93010100030118010C0210050100011004010001
+ - Name: __llvm_covmap
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: 0000000015000000000000000600000002120000106D6364632D67656E6572616C2E637070000000
+ - Name: __llvm_prf_names
+ Type: SHT_PROGBITS
+ Flags: [ SHF_ALLOC, SHF_GNU_RETAIN ]
+ AddressAlign: 0x1
+ Content: 10005F5A347465737462626262016D61696E
+ - Type: SectionHeaderTable
+ Sections:
+ - Name: .strtab
+ - Name: __llvm_covfun
+ - Name: '__llvm_covfun (1)'
+ - Name: __llvm_covmap
+ - Name: __llvm_prf_names
+ - Name: .symtab
+Symbols:
+ - Name: __llvm_covmap
+ Type: STT_SECTION
+ Section: __llvm_covmap
+ - Name: __llvm_prf_names
+ Type: STT_SECTION
+ Section: __llvm_prf_names
+ - Name: __covrec_92FEBEFF6DCBC98Au
+ Type: STT_OBJECT
+ Section: __llvm_covfun
+ Binding: STB_WEAK
+ Size: 0x17C
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_DB956436E78DD5FAu
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (1)'
+ Binding: STB_WEAK
+ Size: 0x2F
+ Other: [ STV_HIDDEN ]
+...
diff --git a/llvm/test/tools/llvm-cov/Inputs/mcdc-general.o b/llvm/test/tools/llvm-cov/Inputs/mcdc-general.o
deleted file mode 100644
index 8bed601221a1459b613300a7386e5251a3fdce1d..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001
literal 6544
zcmd6rZ){sv6~OO(P8uh5Y&UDVq-}~*bu4Aeo82Z^QZ2|%<B+Nm3i|`1usM$7q!IBS
zIWJYICg!c~)=YHekEV?eFuw5#sel+Oh^|#Dw6HIu0tO7Bi4WUKgv2Op8rvGqx$hjm
z>swp>z!$ERcklV#bI&>Vyz}0>&SS}`2}??!peDtqg=9hN!yTRwSHrm21)2{fzL5C*
z1JkRoCRSgc+-Sy`)qf{eZ^YJ4Z8$rLoJWiC%HN&M1kT0R at 1kL{vf&)2ap=X%X99_n
zm#oS~=LD<Dt8e<1T>_J5M$yYVctM*7G()@BGv`3RP3fOjS5OI6u7ED7mD_QlymlV0
z?zkLVgCIhuUIcP&7(%UULc#<`;O_HjJ*s5oJ*P<Xl{Z3_KZ7w6108N8yjqL at dZ?g`
z%!iJx&4)g`bUp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v_J3{o;(rW%0H;R9<PW<Sb<K}(_82ab$91K<KBmZV?y0NmB5RLp#lYhR?
zc>nO%5BueQ8dyF5QS$%1=Sq#t{3T#<z4foq`uHu at -v^6TEXH&44*g(=(t3;^-{0(?
z>%Y<dXX at l1f9LYPxt{@6FMhxIK!YAO)YV%f|3~ZOAGgGQxo?zz_RsrepQhX>|6z(h
z&I_qG*Eh<47Zr}4|E*wy*K_`hz%VD4h``lr)8yZLFPZr(06 at mS_t?TLt>@o6%y~Wc
zV=#eZj+6DiN9(&8P|xeQ|2=RX>#9Ga^*Y0`sr!M;ibna0muP(%7io?2$LL=$z*>ki
zpnkGW{<p&%ujl-~1<W_KQGl)tf7N!J*7JWn at cF@J#y<eSj2-okQ~kzi64&AR()9md
D6TdqO
diff --git a/llvm/test/tools/llvm-cov/Inputs/mcdc-general.yaml b/llvm/test/tools/llvm-cov/Inputs/mcdc-general.yaml
new file mode 100644
index 00000000000000..ceaa04082ef9ec
--- /dev/null
+++ b/llvm/test/tools/llvm-cov/Inputs/mcdc-general.yaml
@@ -0,0 +1,57 @@
+--- !ELF
+FileHeader:
+ Class: ELFCLASS64
+ Data: ELFDATA2LSB
+ OSABI: ELFOSABI_GNU
+ Type: ET_REL
+ Machine: EM_X86_64
+ SectionHeaderStringTable: .strtab
+Sections:
+ - Name: __llvm_covfun
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: 8AC9CB6DFFBEFE9260010000F7C63A91EAF34488EB382E2763226D9301010C010D0D1109151519012121251D2D2D31013D3D413945454930010A2B0B021001010001010107000F010007001B2807040007001B0100080009300D02010302000800090D000D000E301106030002000D000E090013001B090014001530150A02040000140015150019001A30190E0400000019001A05001C018580808008050105002410010100010101070008010007000D280A020007000D3021120102000007000821000C000D302516020000000C000D1D000E008F808080081D000F01241D001300141D00130019280D0200130019302D1A010200001300142D0018001930311E0200000018001929001A01858080800829010500241001010001010107000F010007010F2812040007010F0100080009303D22010300000800093D000D000E304126030200000D000E390107000F390008000930452A0204000008000945000D000E30492E040000000D000E3500100185808080083501050024
+ - Name: '__llvm_covfun (1)'
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: FAD58DE7366495DB130000001800000000000000EB382E2763226D93010100030118010C0210050100011004010001
+ - Name: __llvm_covmap
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: 0000000015000000000000000600000002120000106D6364632D67656E6572616C2E637070000000
+ - Name: __llvm_prf_names
+ Type: SHT_PROGBITS
+ Flags: [ SHF_ALLOC, SHF_GNU_RETAIN ]
+ AddressAlign: 0x1
+ Content: 10005F5A347465737462626262016D61696E
+ - Type: SectionHeaderTable
+ Sections:
+ - Name: .strtab
+ - Name: __llvm_covfun
+ - Name: '__llvm_covfun (1)'
+ - Name: __llvm_covmap
+ - Name: __llvm_prf_names
+ - Name: .symtab
+Symbols:
+ - Name: __llvm_covmap
+ Type: STT_SECTION
+ Section: __llvm_covmap
+ - Name: __llvm_prf_names
+ Type: STT_SECTION
+ Section: __llvm_prf_names
+ - Name: __covrec_92FEBEFF6DCBC98Au
+ Type: STT_OBJECT
+ Section: __llvm_covfun
+ Binding: STB_WEAK
+ Size: 0x17C
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_DB956436E78DD5FAu
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (1)'
+ Binding: STB_WEAK
+ Size: 0x2F
+ Other: [ STV_HIDDEN ]
+...
diff --git a/llvm/test/tools/llvm-cov/Inputs/mcdc-macro.o b/llvm/test/tools/llvm-cov/Inputs/mcdc-macro.o
deleted file mode 100644
index 5b3934816bd222383c5e63188c29bf390a1f19fa..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001
literal 6408
zcmd5=Z){uD6~FgAJ8 at daPSUhZQW_i-P>LGMZj-d`8fK?S)@~`IKt~4@%XOT#TWojE
zYt*3uo=Omv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;F-9<-<lho%tXNckfm_W??!nvAh
zmx(_b2DtBZx)%h*(mDv^Mf_m_^b1O^AI8{|+^5{%UkCpf0{4PWF;oWP{ozWU%=q&#
z!RJEOL4JuA#PKjb#^n5&zYLgKq7{RYM+u70-*28_e=PgOztSK+o=-V0bHDfpC_bMn
zINs-tf2~1$JZ*7Y=6><hq;RwK{}g<>EfV7t6+c4u{dK7K{2BJE-%^A8gJ8sYGoJ?x
z<JW$ylH+Gsfn;WGt}F at R7ymlN=RU)AG{ePina=>$DE?VeFrSwxe;JG$+5edA)8Jnx
z(|!jSD^=<j);)k9BOrd!^urj}!uGuX{MP?TgZksCmeQ(mzxrPzMb-yXMYvX-{Nk%(
zgQ8ylFv#qWxnKR4NMTVA24h}7!+!NYi_Hd<R(J1a+WXc2=?3-3a|YYrtp07-Y?^*Q
zjPZ9cuba7F{jX5|=tHN^TmLSKuh$>nvmBSXU;Q~gua|Q$Wxx7g`-1g<twH_qHx9?=
z`acC2*2EGqxO>z^{cnC-%=#S!6T}jpsTyq}d;U*?r`ewQJ21gx)<Hf-_Bw`RQ}+`W
zJ7#Quv779xXrvLZpCSAmg3mI|0P*WozuhGF1Mh>2?YVw`0nDCSDFds*Rigx*KZpsm
aM>6xr-y>%3s5e0U_cTqS9sVvf<NpVD<Zn3u
diff --git a/llvm/test/tools/llvm-cov/Inputs/mcdc-macro.yaml b/llvm/test/tools/llvm-cov/Inputs/mcdc-macro.yaml
new file mode 100644
index 00000000000000..2ff5aeaaac9b3b
--- /dev/null
+++ b/llvm/test/tools/llvm-cov/Inputs/mcdc-macro.yaml
@@ -0,0 +1,69 @@
+--- !ELF
+FileHeader:
+ Class: ELFCLASS64
+ Data: ELFDATA2LSB
+ OSABI: ELFOSABI_GNU
+ Type: ET_REL
+ Machine: EM_X86_64
+ SectionHeaderStringTable: .strtab
+Sections:
+ - Name: __llvm_covfun
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: 3A78E0F3B66AACDC090000001800000000000000013BA98035CEA5EE0101000101062C0037
+ - Name: '__llvm_covfun (1)'
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: 7DF4935F4A5A2865CB010000B13C91C439097C05013BA98035CEA5EE0C0101010101010101010101010A0121090D012D013D3D41191D111541455155494D2401083A07020101070008010007000D01000700120100070012010007001728090500070017302102010502000700080C000C000D1400110012090016001730060D02000000160017050018018580808008050105000C0101070008010007000D280C020007000D302D0A010200000700081C000C000D29000E018580808008290105000C01010700080100070014010007002028190600070020303D0E010302000700083D000C00143D000D000E304112030402000D000E240012001339001800202C0019001A39001A001F34001E001F350021018580808008350105000C0321020B000C01000B000C300000050402000B000C0819030B001301000B001E01000B001E301D16040302000B00133C000C000D110017001E30151A0300020017001E4400180019022D020B000C300000020000000B000C0241010B000C30451E040002000B000C0339020B000C39000B000C300000020600000B000C014C040B000C0119010B000C0111010B000C0751030B001339000B001E305522060500000B001354000C000D490017001E304D260500000017001E5C001800190151010B000C0149010B000C
+ - Name: '__llvm_covfun (2)'
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: FAD58DE7366495DB090000001800000000000000013BA98035CEA5EE0101000101110C0302
+ - Name: __llvm_covmap
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: 00000000110000000000000006000000020E00000C6D6364632D6D6163726F2E63000000
+ - Name: __llvm_prf_names
+ Type: SHT_PROGBITS
+ Flags: [ SHF_ALLOC, SHF_GNU_RETAIN ]
+ AddressAlign: 0x1
+ Content: 0F0066756E63310166756E63016D61696E
+ - Type: SectionHeaderTable
+ Sections:
+ - Name: .strtab
+ - Name: __llvm_covfun
+ - Name: '__llvm_covfun (1)'
+ - Name: '__llvm_covfun (2)'
+ - Name: __llvm_covmap
+ - Name: __llvm_prf_names
+ - Name: .symtab
+Symbols:
+ - Name: __llvm_covmap
+ Type: STT_SECTION
+ Section: __llvm_covmap
+ - Name: __llvm_prf_names
+ Type: STT_SECTION
+ Section: __llvm_prf_names
+ - Name: __covrec_DCAC6AB6F3E0783Au
+ Type: STT_OBJECT
+ Section: __llvm_covfun
+ Binding: STB_WEAK
+ Size: 0x25
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_65285A4A5F93F47Du
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (1)'
+ Binding: STB_WEAK
+ Size: 0x1E7
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_DB956436E78DD5FAu
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (2)'
+ Binding: STB_WEAK
+ Size: 0x25
+ Other: [ STV_HIDDEN ]
+...
diff --git a/llvm/test/tools/llvm-cov/Inputs/mcdc-maxbs.o b/llvm/test/tools/llvm-cov/Inputs/mcdc-maxbs.o
deleted file mode 100644
index 21f9d3a17dad0d1531e38ec1fbffb7dca3085535..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001
literal 4112
zcmb_eTWFhg6hGhhHBHi{wP}}aT~|o8-iFJ*Ue~%Y(ypxqhl1c!$Fej{yRs%JN!ry>
zv=Cn=7Q8SNd~lC_P;d{9wV+Hk+!zRDA`I`oI4>^>3SI{BoPW+~{`veug?S)7=lss~
zfBu(#FN_`=GY!K6CIgOuA&SPE{ADGo#3<}V&+(#%v_jEdet1hBJo7ZmD-C3=VeK+y
zzFNYJu3PI=b$nGN7%#%P&2u+D`pH`P&KtdCL~ngRzN&(wzTP^HF$=|^>~&7ILCFfm
ziCp74^~QOAzQpFPE9*7NA)Z}hXuVbeXV1K`?$aV(WOJctE(cit5$(`*<tn^%>dPaq
zop|TZi>QD6{N4WPeSPC!Z}h~5KWO<K=jJs$W+>DeY;W%{{QicZVKrH1!0<xA1AE}D
zm6a8r2io8P6FQ9oX(o>PunG0h at km__vO^{WV22&5H7q5CU^j&A);bGJl7jFc916li
z5V6}EO<WL4?a&R6+a1lcJd|n;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1C5wfdL2zPvZI
ze{{yAuJ9)jbE|)n3y+seDakp%`!U!pevRX!+r+nHu<FIJ&?w&@o8zf}`u36f+nwJV
zF7v0a7FoCOYV-fW(GR!rpXa~nGJpCClDfjH&0p%v{z-jVzv$KG|HnPff8J&O^o=R?
zW&WoTqy0A_jDO2C!0UH at 5t6S?!>AA@`z*F$j&Bu!xx@?KKwM<qb%Nt{jAW<pS0!xT
zx!or at K1x9v$@&GljRNguQ~>4|T;@kJlX#imO~kBY#SF3){B6-D$IJZa{1Z9*4<X>}
So&3J#{%>#qG5U^i*8c~u_-R%E
diff --git a/llvm/test/tools/llvm-cov/Inputs/mcdc-maxbs.yaml b/llvm/test/tools/llvm-cov/Inputs/mcdc-maxbs.yaml
new file mode 100644
index 00000000000000..617ad17fa1008c
--- /dev/null
+++ b/llvm/test/tools/llvm-cov/Inputs/mcdc-maxbs.yaml
@@ -0,0 +1,57 @@
+--- !ELF
+FileHeader:
+ Class: ELFCLASS64
+ Data: ELFDATA2LSB
+ OSABI: ELFOSABI_GNU
+ Type: ET_REL
+ Machine: EM_X86_64
+ SectionHeaderStringTable: .strtab
+Sections:
+ - Name: __llvm_covfun
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: 8A68DC3E925EACF9B1000000C67EFC36662A3548DEBA335F42BD13F502010107010502151519111D1D210109090D1101031003020C0107000C05001A009B8080800805001B0023020024018380808008020103003C02000B0021280A04000B003B02000C0014301506010302000C0014150018002030190A03000200180020110025003B110026002E301D0E0204000026002E1D0032003A3021120400000032003A06010116003001001700212803020017002F30091601020000170021090025002F300D1A0200000025002F
+ - Name: '__llvm_covfun (1)'
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: FAD58DE7366495DB2A0000005C83010000000000DEBA335F42BD13F5010101010506010B01020201010B0010200502000B0010050012009380808008050013001902001C001D
+ - Name: __llvm_covmap
+ Type: SHT_PROGBITS
+ Flags: [ SHF_GNU_RETAIN ]
+ AddressAlign: 0x8
+ Content: 00000000110000000000000006000000020E00000C6D6364632D6D617862732E63000000
+ - Name: __llvm_prf_names
+ Type: SHT_PROGBITS
+ Flags: [ SHF_ALLOC, SHF_GNU_RETAIN ]
+ AddressAlign: 0x1
+ Content: 0800737562016D61696E
+ - Type: SectionHeaderTable
+ Sections:
+ - Name: .strtab
+ - Name: __llvm_covfun
+ - Name: '__llvm_covfun (1)'
+ - Name: __llvm_covmap
+ - Name: __llvm_prf_names
+ - Name: .symtab
+Symbols:
+ - Name: __llvm_covmap
+ Type: STT_SECTION
+ Section: __llvm_covmap
+ - Name: __llvm_prf_names
+ Type: STT_SECTION
+ Section: __llvm_prf_names
+ - Name: __covrec_F9AC5E923EDC688Au
+ Type: STT_OBJECT
+ Section: __llvm_covfun
+ Binding: STB_WEAK
+ Size: 0xCD
+ Other: [ STV_HIDDEN ]
+ - Name: __covrec_DB956436E78DD5FAu
+ Type: STT_OBJECT
+ Section: '__llvm_covfun (1)'
+ Binding: STB_WEAK
+ Size: 0x46
+ Other: [ STV_HIDDEN ]
+...
diff --git a/llvm/test/tools/llvm-cov/Inputs/yaml.makefile b/llvm/test/tools/llvm-cov/Inputs/yaml.makefile
new file mode 100644
index 00000000000000..c5b55d28eb3b54
--- /dev/null
+++ b/llvm/test/tools/llvm-cov/Inputs/yaml.makefile
@@ -0,0 +1,16 @@
+# This is for developers' convenience and not expected to be in build steps.
+#
+# Usage:
+# cd /path/to/llvm-project/llvm/test/tools/llvm-cov/Inputs
+# PATH=/path/to/build/bin:$PATH make *.yaml
+
+%.covmap.o: %.o
+ llvm-objcopy \
+ --only-section=__llvm_covfun \
+ --only-section=__llvm_covmap \
+ --only-section=__llvm_prf_names \
+ --strip-unneeded \
+ $< $@
+
+%.yaml: %.covmap.o
+ obj2yaml $< > $@
diff --git a/llvm/test/tools/llvm-cov/branch-c-general.test b/llvm/test/tools/llvm-cov/branch-c-general.test
index 2fa99dfe61532e..93aac3e6ba468c 100644
--- a/llvm/test/tools/llvm-cov/branch-c-general.test
+++ b/llvm/test/tools/llvm-cov/branch-c-general.test
@@ -1,8 +1,9 @@
// Test visualization of general branch constructs in C.
+// RUN: yaml2obj %S/Inputs/branch-c-general.yaml -o %t.o
// RUN: llvm-profdata merge %S/Inputs/branch-c-general.proftext -o %t.profdata
-// RUN: llvm-cov show --show-branches=count %S/Inputs/branch-c-general.o32l -instr-profile %t.profdata -path-equivalence=/tmp,%S/Inputs %S/Inputs/branch-c-general.c | FileCheck %s
-// RUN: llvm-cov report --show-branch-summary %S/Inputs/branch-c-general.o32l -instr-profile %t.profdata -show-functions -path-equivalence=/tmp,%S/Inputs %S/Inputs/branch-c-general.c | FileCheck %s -check-prefix=REPORT
+// RUN: llvm-cov show --show-branches=count %t.o -instr-profile %t.profdata -path-equivalence=/tmp,%S/Inputs %S/Inputs/branch-c-general.c | FileCheck %s
+// RUN: llvm-cov report --show-branch-summary %t.o -instr-profile %t.profdata -show-functions -path-equivalence=/tmp,%S/Inputs %S/Inputs/branch-c-general.c | FileCheck %s -check-prefix=REPORT
// CHECK: simple_loops()
// CHECK: Branch (9:15): [True: 100, False: 1]
@@ -133,15 +134,15 @@
// Test file-level report.
// RUN: llvm-profdata merge %S/Inputs/branch-c-general.proftext -o %t.profdata
-// RUN: llvm-cov report %S/Inputs/branch-c-general.o32l -instr-profile %t.profdata -path-equivalence=/tmp,%S/Inputs %S/Inputs/branch-c-general.c | FileCheck %s -check-prefix=FILEREPORT
+// RUN: llvm-cov report %t.o -instr-profile %t.profdata -path-equivalence=/tmp,%S/Inputs %S/Inputs/branch-c-general.c | FileCheck %s -check-prefix=FILEREPORT
// FILEREPORT: TOTAL{{.*}}172 36 79.07%
// Test color True/False output.
-// RUN: llvm-cov show --use-color --show-branches=count %S/Inputs/branch-c-general.o32l -instr-profile %t.profdata -path-equivalence=/tmp,%S/Inputs %S/Inputs/branch-c-general.c | FileCheck %s -check-prefix=USECOLOR
+// RUN: llvm-cov show --use-color --show-branches=count %t.o -instr-profile %t.profdata -path-equivalence=/tmp,%S/Inputs %S/Inputs/branch-c-general.c | FileCheck %s -check-prefix=USECOLOR
// USECOLOR: Branch ({{[0-9]+}}:7): {{.*}}: 0, {{.*}}0]
// Test html output.
-// RUN: llvm-cov show --show-branch-summary --show-branches=count %S/Inputs/branch-c-general.o32l -instr-profile %t.profdata -path-equivalence=/tmp,%S/Inputs %S/Inputs/branch-c-general.c -format html -o %t.html.dir
+// RUN: llvm-cov show --show-branch-summary --show-branches=count %t.o -instr-profile %t.profdata -path-equivalence=/tmp,%S/Inputs %S/Inputs/branch-c-general.c -format html -o %t.html.dir
// RUN: FileCheck -check-prefix=HTML -input-file=%t.html.dir/coverage/tmp/branch-c-general.c.html %s
// HTML-COUNT-89: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>
// HTML-NOT: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>
diff --git a/llvm/test/tools/llvm-cov/branch-export-json.test b/llvm/test/tools/llvm-cov/branch-export-json.test
index 7cf42860879827..edeb23c9161d25 100644
--- a/llvm/test/tools/llvm-cov/branch-export-json.test
+++ b/llvm/test/tools/llvm-cov/branch-export-json.test
@@ -1,6 +1,7 @@
+// RUN: yaml2obj %S/Inputs/branch-showBranchPercentage.yaml -o %t-branch-showBranchPercentage.o
// RUN: llvm-profdata merge %S/Inputs/branch-showBranchPercentage.proftext -o %t.profdata
-// RUN: llvm-cov export --format=text %S/Inputs/branch-showBranchPercentage.o32l -instr-profile %t.profdata | FileCheck %s
+// RUN: llvm-cov export --format=text %t-branch-showBranchPercentage.o -instr-profile %t.profdata | FileCheck %s
// CHECK: "branches":
// CHECK: 14,7,14,15,1,5,0,0,4
@@ -21,8 +22,9 @@
// CHECK: {"count":30,"covered":26,"notcovered":4,"percent":86.666666666666671}
// Check recursive macro-expansions.
+// RUN: yaml2obj %S/Inputs/branch-macros.yaml -o %t-branch-macros.o
// RUN: llvm-profdata merge %S/Inputs/branch-macros.proftext -o %t.profdata
-// RUN: llvm-cov export --format=text %S/Inputs/branch-macros.o32l -instr-profile %t.profdata | FileCheck %s -check-prefix=MACROS
+// RUN: llvm-cov export --format=text %t-branch-macros.o -instr-profile %t.profdata | FileCheck %s -check-prefix=MACROS
// MACROS: "branches":
// MACROS: 27,10,27,11,0,3,0,0,4
diff --git a/llvm/test/tools/llvm-cov/branch-export-lcov.test b/llvm/test/tools/llvm-cov/branch-export-lcov.test
index fe43dd66de8d04..60b2fed2f3d2cc 100644
--- a/llvm/test/tools/llvm-cov/branch-export-lcov.test
+++ b/llvm/test/tools/llvm-cov/branch-export-lcov.test
@@ -1,7 +1,8 @@
+// RUN: yaml2obj %S/Inputs/branch-showBranchPercentage.yaml -o %t-branch-showBranchPercentage.o
// RUN: llvm-profdata merge %S/Inputs/branch-showBranchPercentage.proftext -o %t.profdata
-// RUN: llvm-cov export --format=lcov %S/Inputs/branch-showBranchPercentage.o32l -instr-profile %t.profdata | FileCheck %s
-// RUN: llvm-cov export --format=lcov --skip-branches %S/Inputs/branch-showBranchPercentage.o32l -instr-profile %t.profdata | FileCheck %s --check-prefix=NOBRANCH
+// RUN: llvm-cov export --format=lcov %t-branch-showBranchPercentage.o -instr-profile %t.profdata | FileCheck %s
+// RUN: llvm-cov export --format=lcov --skip-branches %t-branch-showBranchPercentage.o -instr-profile %t.profdata | FileCheck %s --check-prefix=NOBRANCH
// CHECK-DAG: BRDA:14,0,0,1
// CHECK-DAG: BRDA:14,0,1,5
@@ -38,9 +39,10 @@
// CHECK: BRH:26
// Check recursive macro-expansions.
+// RUN: yaml2obj %S/Inputs/branch-macros.yaml -o %t-branch-macros.o
// RUN: llvm-profdata merge %S/Inputs/branch-macros.proftext -o %t.profdata
-// RUN: llvm-cov export --format=lcov %S/Inputs/branch-macros.o32l -instr-profile %t.profdata | FileCheck %s -check-prefix=MACROS
-// RUN: llvm-cov export --format=lcov --skip-branches %S/Inputs/branch-macros.o32l -instr-profile %t.profdata | FileCheck %s -check-prefix=NOBRANCH
+// RUN: llvm-cov export --format=lcov %t-branch-macros.o -instr-profile %t.profdata | FileCheck %s -check-prefix=MACROS
+// RUN: llvm-cov export --format=lcov --skip-branches %t-branch-macros.o -instr-profile %t.profdata | FileCheck %s -check-prefix=NOBRANCH
// MACROS-COUNT-4: BRDA:17
// MACROS-NOT: BRDA:17
diff --git a/llvm/test/tools/llvm-cov/branch-logical-mixed.test b/llvm/test/tools/llvm-cov/branch-logical-mixed.test
new file mode 100644
index 00000000000000..f570aa999fa4a8
--- /dev/null
+++ b/llvm/test/tools/llvm-cov/branch-logical-mixed.test
@@ -0,0 +1,12 @@
+// RUN: yaml2obj %S/Inputs/branch-logical-mixed.yaml -o %t.o
+// RUN: llvm-profdata merge %S/Inputs/branch-logical-mixed.proftext -o %t.profdata
+// RUN: llvm-cov show --show-branches=count %t.o -instr-profile %t.profdata -path-equivalence=/tmp,%S/Inputs | FileCheck %S/Inputs/branch-logical-mixed.cpp
+// RUN: llvm-cov report --show-branch-summary %t.o -instr-profile %t.profdata -show-functions -path-equivalence=/tmp,%S/Inputs %S/Inputs/branch-logical-mixed.cpp
+| FileCheck %s -check-prefix=REPORT
+
+// REPORT: Name Regions Miss Cover Lines Miss Cover Branches Miss Cover
+// REPORT-NEXT: ---
+// REPORT-NEXT: _Z4funcii 77 15 80.52% 60 2 96.67% 80 30 62.50%
+// REPORT-NEXT: main 1 0 100.00% 5 0 100.00% 0 0 0.00%
+// REPORT-NEXT: ---
+// REPORT-NEXT: TOTAL 78 15 80.77% 65 2 96.92% 80 30 62.50%
diff --git a/llvm/test/tools/llvm-cov/branch-macros.test b/llvm/test/tools/llvm-cov/branch-macros.test
new file mode 100644
index 00000000000000..5d012bb0ec0394
--- /dev/null
+++ b/llvm/test/tools/llvm-cov/branch-macros.test
@@ -0,0 +1,12 @@
+// RUN: yaml2obj %S/Inputs/branch-macros.yaml -o %t.o
+// RUN: llvm-profdata merge %S/Inputs/branch-macros.proftext -o %t.profdata
+// RUN: llvm-cov show --show-expansions --show-branches=count %t.o -instr-profile %t.profdata -path-equivalence=/tmp,%S/Inputs | FileCheck %S/Inputs/branch-macros.cpp
+// RUN: llvm-cov report --show-branch-summary %t.o -instr-profile %t.profdata -show-functions -path-equivalence=/tmp,%S/Inputs %S/Inputs/branch-macros.cpp | FileCheck %s -check-prefix=REPORT
+
+// REPORT: Name Regions Miss Cover Lines Miss Cover Branches Miss Cover
+// REPORT-NEXT: ---
+// REPORT-NEXT: _Z4funcii 28 4 85.71% 18 0 100.00% 30 14 53.33%
+// REPORT-NEXT: _Z5func2ii 13 1 92.31% 8 0 100.00% 10 2 80.00%
+// REPORT-NEXT: main 1 0 100.00% 6 0 100.00% 0 0 0.00%
+// REPORT-NEXT: ---
+// REPORT-NEXT: TOTAL 42 5 88.10% 32 0 100.00% 40 16 60.00%
diff --git a/llvm/test/tools/llvm-cov/branch-noShowBranch.test b/llvm/test/tools/llvm-cov/branch-noShowBranch.test
index 25a98d59481aa1..42763d48e9b5de 100644
--- a/llvm/test/tools/llvm-cov/branch-noShowBranch.test
+++ b/llvm/test/tools/llvm-cov/branch-noShowBranch.test
@@ -1,7 +1,8 @@
+// RUN: yaml2obj %S/Inputs/branch-c-general.yaml -o %t.o
// RUN: llvm-profdata merge %S/Inputs/branch-c-general.proftext -o %t.profdata
-// RUN: llvm-cov show %S/Inputs/branch-c-general.o32l -instr-profile %t.profdata -path-equivalence=/tmp,%S/Inputs | FileCheck %s
-// RUN: llvm-cov report %S/Inputs/branch-c-general.o32l --show-branch-summary=false -instr-profile %t.profdata -show-functions -path-equivalence=/tmp,%S/Inputs %S/Inputs/branch-c-general.c | FileCheck %s -check-prefix=REPORT
+// RUN: llvm-cov show %t.o -instr-profile %t.profdata -path-equivalence=/tmp,%S/Inputs | FileCheck %s
+// RUN: llvm-cov report %t.o --show-branch-summary=false -instr-profile %t.profdata -show-functions -path-equivalence=/tmp,%S/Inputs %S/Inputs/branch-c-general.c | FileCheck %s -check-prefix=REPORT
// CHECK-NOT: | Branch
diff --git a/llvm/test/tools/llvm-cov/branch-showBranchPercentage.c b/llvm/test/tools/llvm-cov/branch-showBranchPercentage.c
deleted file mode 100644
index a649462116a08e..00000000000000
--- a/llvm/test/tools/llvm-cov/branch-showBranchPercentage.c
+++ /dev/null
@@ -1,77 +0,0 @@
-// Test visualization of branch taken percentages
-
-// RUN: llvm-profdata merge %S/Inputs/branch-showBranchPercentage.proftext -o %t.profdata
-// RUN: llvm-cov show --show-branches=percent %S/Inputs/branch-showBranchPercentage.o32l -instr-profile %t.profdata -path-equivalence=/tmp,%S %s | FileCheck %s
-
-#include <stdio.h>
-#include <stdlib.h>
-
-extern void __llvm_profile_write_file(void);
-
-int main(int argc, char *argv[])
-{
- int i = 0;
- if (argc < 3) // CHECK: Branch ([[@LINE]]:7): [True: 16.67%, False: 83.33%]
- {
- __llvm_profile_write_file();
- return 0;
- }
-
- int a = atoi(argv[1]);
- int b = atoi(argv[2]);
-
- // CHECK: Branch ([[@LINE+4]]:8): [True: 20.00%, False: 80.00%]
- // CHECK: Branch ([[@LINE+3]]:18): [True: 0.00%, False: 100.00%]
- // CHECK: Branch ([[@LINE+2]]:29): [True: 0.00%, False: 100.00%]
- // CHECK: Branch ([[@LINE+1]]:40): [True: 40.00%, False: 60.00%]
- if ((a == 0 && b == 2) || b == 34 || a == b)
- printf("case1\n");
-
- b = (a != 0 || a == 2) ? b : b+2; // CHECK: Branch ([[@LINE]]:8): [True: 80.00%, False: 20.00%]
- // CHECK: Branch ([[@LINE-1]]:18): [True: 0.00%, False: 100.00%]
- b = (a != 0 && a == 1); // CHECK: Branch ([[@LINE]]:8): [True: 80.00%, False: 20.00%]
- // CHECK: Branch ([[@LINE-1]]:18): [True: 25.00%, False: 75.00%]
- for (i = 0; i < b; i++) { a = 2 + b + b; }
- // CHECK: Branch ([[@LINE-1]]:15): [True: 16.67%, False: 83.33%]
-
- b = a;
-
- switch (a)
- {
- case 0: // CHECK: Branch ([[@LINE]]:5): [True: 20.00%, False: 80.00%]
- printf("case0\n");
- case 2: // CHECK: Branch ([[@LINE]]:5): [True: 20.00%, False: 80.00%]
- printf("case2\n");
- case 3: // CHECK: Branch ([[@LINE]]:5): [True: 0.00%, False: 100.00%]
- printf("case3\n");
- default: break; // CHECK: Branch ([[@LINE]]:5): [True: 60.00%, False: 40.00%]
- }
-
- i = 0;
- do {
- printf("loop\n");
- } while (i++ < 10); // CHECK: Branch ([[@LINE]]:12): [True: 90.91%, False: 9.09%]
-
- __llvm_profile_write_file();
-
- return b;
-}
-// RUN: llvm-profdata merge %S/Inputs/branch-showBranchPercentage.proftext -o %t.profdata
-// RUN: llvm-cov show --show-branches=percent %S/Inputs/branch-showBranchPercentage.o32l -instr-profile %t.profdata -path-equivalence=/tmp,%S %s -format html -o %t.html.dir
-
-// Test html output.
-// RUN: FileCheck -check-prefix=HTML -input-file=%t.html.dir/coverage/tmp/branch-showBranchPercentage.c.html %s
-// HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}16.67%,{{.*}}83.33%]
-// HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}20.00%,{{.*}}80.00%]
-// HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}0.00%,{{.*}}100.00%]
-// HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}0.00%,{{.*}}100.00%]
-// HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}40.00%,{{.*}}60.00%]
-// HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}80.00%,{{.*}}20.00%]
-// HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}0.00%,{{.*}}100.00%]
-// HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}80.00%,{{.*}}20.00%]
-// HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}25.00%,{{.*}}75.00%]
-// HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}16.67%,{{.*}}83.33%]
-// HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}20.00%,{{.*}}80.00%]
-// HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}20.00%,{{.*}}80.00%]
-// HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}0.00%,{{.*}}100.00%]
-// HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}60.00%,{{.*}}40.00%]
diff --git a/llvm/test/tools/llvm-cov/branch-showBranchPercentage.test b/llvm/test/tools/llvm-cov/branch-showBranchPercentage.test
new file mode 100644
index 00000000000000..fe0bc2c7eec378
--- /dev/null
+++ b/llvm/test/tools/llvm-cov/branch-showBranchPercentage.test
@@ -0,0 +1,25 @@
+// Test visualization of branch taken percentages
+
+// RUN: yaml2obj %S/Inputs/branch-showBranchPercentage.yaml -o %t.o
+// RUN: llvm-profdata merge %S/Inputs/branch-showBranchPercentage.proftext -o %t.profdata
+// RUN: llvm-cov show --show-branches=percent %t.o -instr-profile %t.profdata -path-equivalence=/tmp,%S/Inputs | FileCheck %S/Inputs/branch-showBranchPercentage.c
+
+// RUN: llvm-profdata merge %S/Inputs/branch-showBranchPercentage.proftext -o %t.profdata
+// RUN: llvm-cov show --show-branches=percent %t.o -instr-profile %t.profdata -path-equivalence=/tmp,%S/Inputs -format html -o %t.html.dir
+
+// Test html output.
+// RUN: FileCheck -check-prefix=HTML -input-file=%t.html.dir/coverage/tmp/branch-showBranchPercentage.c.html %s
+// HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}16.67%,{{.*}}83.33%]
+// HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}20.00%,{{.*}}80.00%]
+// HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}0.00%,{{.*}}100.00%]
+// HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}0.00%,{{.*}}100.00%]
+// HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}40.00%,{{.*}}60.00%]
+// HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}80.00%,{{.*}}20.00%]
+// HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}0.00%,{{.*}}100.00%]
+// HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}80.00%,{{.*}}20.00%]
+// HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}25.00%,{{.*}}75.00%]
+// HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}16.67%,{{.*}}83.33%]
+// HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}20.00%,{{.*}}80.00%]
+// HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}20.00%,{{.*}}80.00%]
+// HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}0.00%,{{.*}}100.00%]
+// HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}60.00%,{{.*}}40.00%]
diff --git a/llvm/test/tools/llvm-cov/branch-templates.cpp b/llvm/test/tools/llvm-cov/branch-templates.test
similarity index 54%
rename from llvm/test/tools/llvm-cov/branch-templates.cpp
rename to llvm/test/tools/llvm-cov/branch-templates.test
index 4797428f8835ae..1c18356043f66f 100644
--- a/llvm/test/tools/llvm-cov/branch-templates.cpp
+++ b/llvm/test/tools/llvm-cov/branch-templates.test
@@ -1,41 +1,8 @@
+// RUN: yaml2obj %S/Inputs/branch-templates.yaml -o %t.o
// RUN: llvm-profdata merge %S/Inputs/branch-templates.proftext -o %t.profdata
-// RUN: llvm-cov show --show-expansions --show-branches=count %S/Inputs/branch-templates.o32l -instr-profile %t.profdata -path-equivalence=/tmp,%S %s | FileCheck %s
-// RUN: llvm-cov report --show-branch-summary %S/Inputs/branch-templates.o32l -instr-profile %t.profdata -show-functions -path-equivalence=/tmp,%S %s | FileCheck %s -check-prefix=REPORT
-// RUN: llvm-cov report --show-branch-summary %S/Inputs/branch-templates.o32l -instr-profile %t.profdata -path-equivalence=/tmp,%S %s | FileCheck %s -check-prefix=REPORTFILE
-
-#include <stdio.h>
-template<typename T>
-void unused(T x) {
- return;
-}
-
-template<typename T>
-int func(T x) {
- if(x) // CHECK: | Branch ([[@LINE]]:6): [True: 0, False: 1]
- return 0; // CHECK: | Branch ([[@LINE-1]]:6): [True: 1, False: 0]
- else // CHECK: | Branch ([[@LINE-2]]:6): [True: 0, False: 1]
- return 1;
- int j = 1;
-}
-
- // CHECK-LABEL: _Z4funcIiEiT_:
- // CHECK: | | Branch ([[@LINE-8]]:6): [True: 0, False: 1]
- // CHECK-LABEL: _Z4funcIbEiT_:
- // CHECK: | | Branch ([[@LINE-10]]:6): [True: 1, False: 0]
- // CHECK-LABEL: _Z4funcIfEiT_:
- // CHECK: | | Branch ([[@LINE-12]]:6): [True: 0, False: 1]
-
-extern "C" { extern void __llvm_profile_write_file(void); }
-int main() {
- if (func<int>(0)) // CHECK: | Branch ([[@LINE]]:7): [True: 1, False: 0]
- printf("case1\n");
- if (func<bool>(true)) // CHECK: | Branch ([[@LINE]]:7): [True: 0, False: 1]
- printf("case2\n");
- if (func<float>(0.0)) // CHECK: | Branch ([[@LINE]]:7): [True: 1, False: 0]
- printf("case3\n");
- __llvm_profile_write_file();
- return 0;
-}
+// RUN: llvm-cov show --show-expansions --show-branches=count %t.o -instr-profile %t.profdata -path-equivalence=/tmp,%S/Inputs | FileCheck %S/Inputs/branch-templates.cpp
+// RUN: llvm-cov report --show-branch-summary %t.o -instr-profile %t.profdata -show-functions -path-equivalence=/tmp,%S/Inputs %S/Inputs/branch-templates.cpp | FileCheck %s -check-prefix=REPORT
+// RUN: llvm-cov report --show-branch-summary %t.o -instr-profile %t.profdata -path-equivalence=/tmp,%S/Inputs | FileCheck %s -check-prefix=REPORTFILE
// REPORT: Name Regions Miss Cover Lines Miss Cover Branches Miss Cover
// REPORT-NEXT: ---
diff --git a/llvm/test/tools/llvm-cov/mcdc-const.test b/llvm/test/tools/llvm-cov/mcdc-const.test
index 5424625cf6a6b5..e6abaa1fa6da86 100644
--- a/llvm/test/tools/llvm-cov/mcdc-const.test
+++ b/llvm/test/tools/llvm-cov/mcdc-const.test
@@ -1,7 +1,8 @@
// Test visualization of MC/DC constructs for constant-folded condition masking.
+// RUN: yaml2obj %S/Inputs/mcdc-const.yaml -o %t.o
// RUN: llvm-profdata merge %S/Inputs/mcdc-const.proftext -o %t.profdata
-// RUN: llvm-cov show --show-branches=count --show-mcdc %S/Inputs/mcdc-const.o -instr-profile %t.profdata -path-equivalence=.,%S/Inputs | FileCheck %s -check-prefix=CHECKGENERALCASE
+// RUN: llvm-cov show --show-branches=count --show-mcdc %t.o -instr-profile %t.profdata -path-equivalence=.,%S/Inputs | FileCheck %s -check-prefix=CHECKGENERALCASE
// CHECKGENERALCASE: ------------------
// CHECKGENERALCASE-NEXT: | Branch (12:8): [True: 4, False: 1]
@@ -34,9 +35,10 @@
// CHECKGENERALCASE-NEXT: |
// CHECKGENERALCASE-NEXT: ------------------
+// RUN: yaml2obj %S/Inputs/mcdc-const-folding.yaml -o %t-folding.o
// RUN: llvm-profdata merge %S/Inputs/mcdc-const-folding.proftext -o %t.profdata
-// RUN: llvm-cov show --show-mcdc %S/Inputs/mcdc-const-folding.o -instr-profile %t.profdata -path-equivalence=.,%S/Inputs | FileCheck %s -check-prefix=CHECKFULLCASE
-// RUN: llvm-cov report --show-mcdc-summary %S/Inputs/mcdc-const-folding.o -instr-profile %t.profdata -show-functions -path-equivalence=.,%S/Inputs %S/Inputs/mcdc-const-folding.cpp | FileCheck %s -check-prefix=REPORT
+// RUN: llvm-cov show --show-mcdc %t-folding.o -instr-profile %t.profdata -path-equivalence=.,%S/Inputs | FileCheck %s -check-prefix=CHECKFULLCASE
+// RUN: llvm-cov report --show-mcdc-summary %t-folding.o -instr-profile %t.profdata -show-functions -path-equivalence=.,%S/Inputs %S/Inputs/mcdc-const-folding.cpp | FileCheck %s -check-prefix=REPORT
// CHECKFULLCASE: | 1 { C, - = F }
// CHECKFULLCASE: | C1-Pair: constant folded
diff --git a/llvm/test/tools/llvm-cov/mcdc-export-json.test b/llvm/test/tools/llvm-cov/mcdc-export-json.test
index c2cebf52db8cc5..e4e349a0fe900a 100644
--- a/llvm/test/tools/llvm-cov/mcdc-export-json.test
+++ b/llvm/test/tools/llvm-cov/mcdc-export-json.test
@@ -1,5 +1,6 @@
+// RUN: yaml2obj %S/Inputs/mcdc-general.yaml -o %t.o
// RUN: llvm-profdata merge %S/Inputs/mcdc-general.proftext -o %t.profdata
-// RUN: llvm-cov export --format=text %S/Inputs/mcdc-general.o -instr-profile %t.profdata | FileCheck %s
+// RUN: llvm-cov export --format=text %t.o -instr-profile %t.profdata | FileCheck %s
// CHECK: 12,7,12,27,0,5,[true,true,true,true]
// CHECK: 15,7,15,13,0,5,[true,true]
diff --git a/llvm/test/tools/llvm-cov/mcdc-general-18.test b/llvm/test/tools/llvm-cov/mcdc-general-18.test
index 8707238c4cdcbe..1adeae4cc6fd6b 100644
--- a/llvm/test/tools/llvm-cov/mcdc-general-18.test
+++ b/llvm/test/tools/llvm-cov/mcdc-general-18.test
@@ -1,20 +1,21 @@
// Test Version11 (clang-18) files.
// mcdc-general.test is used as test patterns.
-// RUN: llvm-cov show --show-mcdc %S/Inputs/mcdc-general-18.o -instr-profile %S/Inputs/mcdc-general-18.profdata -path-equivalence=.,%S/Inputs | FileCheck %S/mcdc-general.test
-// RUN: llvm-cov report --show-mcdc-summary %S/Inputs/mcdc-general-18.o -instr-profile %S/Inputs/mcdc-general-18.profdata -show-functions -path-equivalence=.,%S/Inputs %S/Inputs/mcdc-general.cpp | FileCheck %S/mcdc-general.test -check-prefix=REPORT
+// RUN: yaml2obj %S/Inputs/mcdc-general-18.yaml -o %t.o
+// RUN: llvm-cov show --show-mcdc %t.o -instr-profile %S/Inputs/mcdc-general-18.profdata -path-equivalence=.,%S/Inputs | FileCheck %S/mcdc-general.test
+// RUN: llvm-cov report --show-mcdc-summary %t.o -instr-profile %S/Inputs/mcdc-general-18.profdata -show-functions -path-equivalence=.,%S/Inputs %S/Inputs/mcdc-general.cpp | FileCheck %S/mcdc-general.test -check-prefix=REPORT
// Turn off MC/DC visualization.
-// RUN: llvm-cov show %S/Inputs/mcdc-general-18.o -instr-profile %S/Inputs/mcdc-general-18.profdata -path-equivalence=.,%S/Inputs | FileCheck %S/mcdc-general.test -check-prefix=NOMCDC
+// RUN: llvm-cov show %t.o -instr-profile %S/Inputs/mcdc-general-18.profdata -path-equivalence=.,%S/Inputs | FileCheck %S/mcdc-general.test -check-prefix=NOMCDC
// Turn off MC/DC summary.
-// RUN: llvm-cov report %S/Inputs/mcdc-general-18.o -instr-profile %S/Inputs/mcdc-general-18.profdata -show-functions -path-equivalence=.,%S/Inputs %S/Inputs/mcdc-general.cpp | FileCheck %S/mcdc-general.test -check-prefix=REPORT_NOMCDC
+// RUN: llvm-cov report %t.o -instr-profile %S/Inputs/mcdc-general-18.profdata -show-functions -path-equivalence=.,%S/Inputs %S/Inputs/mcdc-general.cpp | FileCheck %S/mcdc-general.test -check-prefix=REPORT_NOMCDC
// Test file-level report.
-// RUN: llvm-cov report --show-mcdc-summary %S/Inputs/mcdc-general-18.o -instr-profile %S/Inputs/mcdc-general-18.profdata -path-equivalence=.,%S/Inputs %S/Inputs/mcdc-general.cpp | FileCheck %S/mcdc-general.test -check-prefix=FILEREPORT
+// RUN: llvm-cov report --show-mcdc-summary %t.o -instr-profile %S/Inputs/mcdc-general-18.profdata -path-equivalence=.,%S/Inputs %S/Inputs/mcdc-general.cpp | FileCheck %S/mcdc-general.test -check-prefix=FILEREPORT
// Test html output.
// RUN: rm -rf %t.html.dir
-// RUN: llvm-cov show --show-mcdc-summary --show-mcdc %S/Inputs/mcdc-general-18.o -instr-profile %S/Inputs/mcdc-general-18.profdata -path-equivalence=.,%S/Inputs -format html -o %t.html.dir
+// RUN: llvm-cov show --show-mcdc-summary --show-mcdc %t.o -instr-profile %S/Inputs/mcdc-general-18.profdata -path-equivalence=.,%S/Inputs -format html -o %t.html.dir
// RUN: FileCheck -check-prefix=HTML -input-file=%t.html.dir/coverage/mcdc-general.cpp.html %S/mcdc-general.test
// RUN: FileCheck -check-prefix HTML-INDEX -input-file %t.html.dir/index.html %S/mcdc-general.test
diff --git a/llvm/test/tools/llvm-cov/mcdc-general-none.test b/llvm/test/tools/llvm-cov/mcdc-general-none.test
index b57b35d49c8c11..a30ebf4b83b3b7 100644
--- a/llvm/test/tools/llvm-cov/mcdc-general-none.test
+++ b/llvm/test/tools/llvm-cov/mcdc-general-none.test
@@ -1,8 +1,9 @@
// Test visualization of general MC/DC constructs with 0 executed test vectors.
+// RUN: yaml2obj %S/Inputs/mcdc-general.yaml -o %t.o
// RUN: llvm-profdata merge %S/Inputs/mcdc-general-none.proftext -o %t.profdata
-// RUN: llvm-cov show --show-mcdc %S/Inputs/mcdc-general.o -instr-profile %t.profdata -path-equivalence=.,%S/Inputs | FileCheck %s
-// RUN: llvm-cov report --show-mcdc-summary %S/Inputs/mcdc-general.o -instr-profile %t.profdata -show-functions -path-equivalence=.,%S/Inputs %S/Inputs/mcdc-general.cpp | FileCheck %s -check-prefix=REPORT
+// RUN: llvm-cov show --show-mcdc %t.o -instr-profile %t.profdata -path-equivalence=.,%S/Inputs | FileCheck %s
+// RUN: llvm-cov report --show-mcdc-summary %t.o -instr-profile %t.profdata -show-functions -path-equivalence=.,%S/Inputs %S/Inputs/mcdc-general.cpp | FileCheck %s -check-prefix=REPORT
// CHECK: test(bool
@@ -29,7 +30,7 @@
// Turn off MC/DC visualization.
-// RUN: llvm-cov show %S/Inputs/mcdc-general.o -instr-profile %t.profdata -path-equivalence=.,%S/Inputs | FileCheck %s -check-prefix=NOMCDC
+// RUN: llvm-cov show %t.o -instr-profile %t.profdata -path-equivalence=.,%S/Inputs | FileCheck %s -check-prefix=NOMCDC
// NOMCDC-NOT: MC/DC Decision Region
// REPORT: Name Regions Miss Cover Lines Miss Cover Branches Miss Cover MC/DC Conditions Miss Cover
@@ -40,18 +41,18 @@
// REPORT-NEXT: TOTAL 26 0 100.00% 20 0 100.00% 24 2 91.67% 12 12 0.00%
// Turn off MC/DC summary.
-// RUN: llvm-cov report %S/Inputs/mcdc-general.o -instr-profile %t.profdata -show-functions -path-equivalence=.,%S/Inputs %S/Inputs/mcdc-general.cpp | FileCheck %s -check-prefix=REPORT_NOMCDC
+// RUN: llvm-cov report %t.o -instr-profile %t.profdata -show-functions -path-equivalence=.,%S/Inputs %S/Inputs/mcdc-general.cpp | FileCheck %s -check-prefix=REPORT_NOMCDC
// REPORT_NOMCDC-NOT: TOTAL{{.*}}12 12 0.00%
// Test file-level report.
-// RUN: llvm-cov report --show-mcdc-summary %S/Inputs/mcdc-general.o -instr-profile %t.profdata -path-equivalence=.,%S/Inputs %S/Inputs/mcdc-general.cpp | FileCheck %s -check-prefix=FILEREPORT
+// RUN: llvm-cov report --show-mcdc-summary %t.o -instr-profile %t.profdata -path-equivalence=.,%S/Inputs %S/Inputs/mcdc-general.cpp | FileCheck %s -check-prefix=FILEREPORT
// FILEREPORT: TOTAL{{.*}}12 12 0.00%
// Test html output.
// RUN: rm -rf %t.html.dir
-// RUN: llvm-cov show --show-mcdc-summary --show-mcdc %S/Inputs/mcdc-general.o -instr-profile %t.profdata -path-equivalence=.,%S/Inputs -format html -o %t.html.dir
+// RUN: llvm-cov show --show-mcdc-summary --show-mcdc %t.o -instr-profile %t.profdata -path-equivalence=.,%S/Inputs -format html -o %t.html.dir
// RUN: FileCheck -check-prefix=HTML -input-file=%t.html.dir/coverage/mcdc-general.cpp.html %s
// HTML-COUNT-4: MC/DC Decision Region (<span class='line-number'><a href='#L{{[0-9]+}}'><span>
diff --git a/llvm/test/tools/llvm-cov/mcdc-general.test b/llvm/test/tools/llvm-cov/mcdc-general.test
index c1e95cb2bd92ac..7cbd2838eddabf 100644
--- a/llvm/test/tools/llvm-cov/mcdc-general.test
+++ b/llvm/test/tools/llvm-cov/mcdc-general.test
@@ -1,8 +1,9 @@
// Test visualization of general MC/DC constructs.
+// RUN: yaml2obj %S/Inputs/mcdc-general.yaml -o %t.o
// RUN: llvm-profdata merge %S/Inputs/mcdc-general.proftext -o %t.profdata
-// RUN: llvm-cov show --show-mcdc %S/Inputs/mcdc-general.o -instr-profile %t.profdata -path-equivalence=.,%S/Inputs | FileCheck %s
-// RUN: llvm-cov report --show-mcdc-summary %S/Inputs/mcdc-general.o -instr-profile %t.profdata -show-functions -path-equivalence=.,%S/Inputs %S/Inputs/mcdc-general.cpp | FileCheck %s -check-prefix=REPORT
+// RUN: llvm-cov show --show-mcdc %t.o -instr-profile %t.profdata -path-equivalence=.,%S/Inputs | FileCheck %s
+// RUN: llvm-cov report --show-mcdc-summary %t.o -instr-profile %t.profdata -show-functions -path-equivalence=.,%S/Inputs %S/Inputs/mcdc-general.cpp | FileCheck %s -check-prefix=REPORT
// CHECK: test(bool
@@ -95,7 +96,7 @@
// CHECK-NEXT: ------------------
// Turn off MC/DC visualization.
-// RUN: llvm-cov show %S/Inputs/mcdc-general.o -instr-profile %t.profdata -path-equivalence=.,%S/Inputs | FileCheck %s -check-prefix=NOMCDC
+// RUN: llvm-cov show %t.o -instr-profile %t.profdata -path-equivalence=.,%S/Inputs | FileCheck %s -check-prefix=NOMCDC
// NOMCDC-NOT: MC/DC Decision Region
// REPORT: Name Regions Miss Cover Lines Miss Cover Branches Miss Cover MC/DC Conditions Miss Cover
@@ -106,18 +107,18 @@
// REPORT-NEXT: TOTAL 26 0 100.00% 20 0 100.00% 24 2 91.67% 12 2 83.33%
// Turn off MC/DC summary.
-// RUN: llvm-cov report %S/Inputs/mcdc-general.o -instr-profile %t.profdata -show-functions -path-equivalence=.,%S/Inputs %S/Inputs/mcdc-general.cpp | FileCheck %s -check-prefix=REPORT_NOMCDC
+// RUN: llvm-cov report %t.o -instr-profile %t.profdata -show-functions -path-equivalence=.,%S/Inputs %S/Inputs/mcdc-general.cpp | FileCheck %s -check-prefix=REPORT_NOMCDC
// REPORT_NOMCDC-NOT: TOTAL{{.*}}12 2 83.33%
// Test file-level report.
-// RUN: llvm-cov report --show-mcdc-summary %S/Inputs/mcdc-general.o -instr-profile %t.profdata -path-equivalence=.,%S/Inputs %S/Inputs/mcdc-general.cpp | FileCheck %s -check-prefix=FILEREPORT
+// RUN: llvm-cov report --show-mcdc-summary %t.o -instr-profile %t.profdata -path-equivalence=.,%S/Inputs %S/Inputs/mcdc-general.cpp | FileCheck %s -check-prefix=FILEREPORT
// FILEREPORT: TOTAL{{.*}}12 2 83.33%
// Test html output.
// RUN: rm -rf %t.html.dir
-// RUN: llvm-cov show --show-mcdc-summary --show-mcdc %S/Inputs/mcdc-general.o -instr-profile %t.profdata -path-equivalence=.,%S/Inputs -format html -o %t.html.dir
+// RUN: llvm-cov show --show-mcdc-summary --show-mcdc %t.o -instr-profile %t.profdata -path-equivalence=.,%S/Inputs -format html -o %t.html.dir
// RUN: FileCheck -check-prefix=HTML -input-file=%t.html.dir/coverage/mcdc-general.cpp.html %s
// HTML-COUNT-4: MC/DC Decision Region (<span class='line-number'><a href='#L{{[0-9]+}}'><span>
diff --git a/llvm/test/tools/llvm-cov/mcdc-macro.test b/llvm/test/tools/llvm-cov/mcdc-macro.test
index 14dd5ebd68eb1a..989c7d2fe3039b 100644
--- a/llvm/test/tools/llvm-cov/mcdc-macro.test
+++ b/llvm/test/tools/llvm-cov/mcdc-macro.test
@@ -1,7 +1,8 @@
// Test visualization of MC/DC constructs for branches in macro expansions.
+// RUN: yaml2obj %S/Inputs/mcdc-macro.yaml -o %t.o
// RUN: llvm-profdata merge %S/Inputs/mcdc-macro.proftext -o %t.profdata
-// RUN: llvm-cov show --show-expansions --show-branches=count --show-mcdc %S/Inputs/mcdc-macro.o -instr-profile %t.profdata --compilation-dir=%S/Inputs | FileCheck %s
+// RUN: llvm-cov show --show-expansions --show-branches=count --show-mcdc %t.o -instr-profile %t.profdata --compilation-dir=%S/Inputs | FileCheck %s
// CHECK: | | | Branch (2:11): [Folded - Ignored]
// CHECK: | | | Branch (3:11): [True: 1, False: 0]
diff --git a/llvm/test/tools/llvm-cov/mcdc-maxbs.test b/llvm/test/tools/llvm-cov/mcdc-maxbs.test
index c6bd18048fb95f..78046b6493b393 100644
--- a/llvm/test/tools/llvm-cov/mcdc-maxbs.test
+++ b/llvm/test/tools/llvm-cov/mcdc-maxbs.test
@@ -1,6 +1,8 @@
# Test not to trigger the assertion failure in llvm-cov with empty bitmap.
# REQUIRES: asserts
+// RUN: yaml2obj %S/Inputs/mcdc-maxbs.yaml -o %t.o
+
# mcdc-maxbs.o contains the record:
#
# sub:
@@ -26,7 +28,7 @@
# by trailing uninitialized garbage.
# RUN: llvm-profdata merge %S/Inputs/mcdc-maxbs.proftext -o %t.profdata
-# RUN: llvm-cov report --show-mcdc-summary %S/Inputs/mcdc-maxbs.o -instr-profile %t.profdata
+# RUN: llvm-cov report --show-mcdc-summary %t.o -instr-profile %t.profdata
# Instructions for regenerating the test object:
>From 9f83734c570e554af44293cf517a86265c0ec191 Mon Sep 17 00:00:00 2001
From: NAKAMURA Takumi <geek4civic at gmail.com>
Date: Wed, 13 Nov 2024 01:13:26 +0900
Subject: [PATCH 2/3] Update usage comment in yaml.makefile
I was using `GNUmakefile` just before creating this request.
---
llvm/test/tools/llvm-cov/Inputs/yaml.makefile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/llvm/test/tools/llvm-cov/Inputs/yaml.makefile b/llvm/test/tools/llvm-cov/Inputs/yaml.makefile
index c5b55d28eb3b54..fd29aa26baed10 100644
--- a/llvm/test/tools/llvm-cov/Inputs/yaml.makefile
+++ b/llvm/test/tools/llvm-cov/Inputs/yaml.makefile
@@ -2,7 +2,7 @@
#
# Usage:
# cd /path/to/llvm-project/llvm/test/tools/llvm-cov/Inputs
-# PATH=/path/to/build/bin:$PATH make *.yaml
+# PATH=/path/to/build/bin:$PATH make -f yaml.makefile *.yaml
%.covmap.o: %.o
llvm-objcopy \
>From 7d62e4d970cbfde0de0eb3cf906cd2504de5a012 Mon Sep 17 00:00:00 2001
From: NAKAMURA Takumi <geek4civic at gmail.com>
Date: Wed, 13 Nov 2024 23:13:44 +0900
Subject: [PATCH 3/3] Reformat tests
---
llvm/test/tools/llvm-cov/branch-c-general.test | 2 +-
llvm/test/tools/llvm-cov/branch-noShowBranch.test | 8 ++++----
llvm/test/tools/llvm-cov/branch-showBranchPercentage.test | 2 ++
llvm/test/tools/llvm-cov/branch-templates.test | 6 +++---
4 files changed, 10 insertions(+), 8 deletions(-)
diff --git a/llvm/test/tools/llvm-cov/branch-c-general.test b/llvm/test/tools/llvm-cov/branch-c-general.test
index 93aac3e6ba468c..8c58c1536f1583 100644
--- a/llvm/test/tools/llvm-cov/branch-c-general.test
+++ b/llvm/test/tools/llvm-cov/branch-c-general.test
@@ -115,7 +115,7 @@
-// REPORT: Name Regions Miss Cover Lines Miss Cover Branches Miss Cover
+// REPORT: Name Regions Miss Cover Lines Miss Cover Branches Miss Cover
// REPORT-NEXT: ---
// REPORT-NEXT: simple_loops 8 0 100.00% 9 0 100.00% 6 0 100.00%
// REPORT-NEXT: conditionals 24 0 100.00% 15 0 100.00% 16 2 87.50%
diff --git a/llvm/test/tools/llvm-cov/branch-noShowBranch.test b/llvm/test/tools/llvm-cov/branch-noShowBranch.test
index 42763d48e9b5de..4f16d6629bf120 100644
--- a/llvm/test/tools/llvm-cov/branch-noShowBranch.test
+++ b/llvm/test/tools/llvm-cov/branch-noShowBranch.test
@@ -6,9 +6,9 @@
// CHECK-NOT: | Branch
-// REPORT: Name Regions Miss Cover Lines Miss Cover
+// REPORT: Name Regions Miss Cover Lines Miss Cover
// REPORT-NOT: Name Regions Miss Cover Lines Miss Cover Branches Miss Cover
-// REPORT: ---
+// REPORT: ---
// REPORT-NOT: simple_loops 8 0 100.00% 9 0 100.00% 6 0 100.00%
// REPORT-NOT: conditionals 24 0 100.00% 15 0 100.00% 16 2 87.50%
// REPORT-NOT: early_exits 20 4 80.00% 25 2 92.00% 16 6 62.50%
@@ -21,6 +21,6 @@
// REPORT-NOT: do_fallthrough 9 0 100.00% 12 0 100.00% 6 0 100.00%
// REPORT-NOT: main 1 0 100.00% 16 0 100.00% 0 0 0.00%
// REPORT-NOT: c-general.c:static_func 4 0 100.00% 4 0 100.00% 2 0 100.00%
-// REPORT: TOTAL 197 24 87.82% 234 8 96.58%
-// REPORT-NOT: TOTAL 197 24 87.82% 234 13 94.44% 174 38 78.16%
+// REPORT: TOTAL 197 24 87.82% 234 8 96.58%
+// REPORT-NOT: TOTAL 197 24 87.82% 234 13 94.44% 174 38 78.16%
diff --git a/llvm/test/tools/llvm-cov/branch-showBranchPercentage.test b/llvm/test/tools/llvm-cov/branch-showBranchPercentage.test
index fe0bc2c7eec378..5365d4419c2e98 100644
--- a/llvm/test/tools/llvm-cov/branch-showBranchPercentage.test
+++ b/llvm/test/tools/llvm-cov/branch-showBranchPercentage.test
@@ -1,5 +1,6 @@
// Test visualization of branch taken percentages
+// RUN: rm -rf %t.html.dir
// RUN: yaml2obj %S/Inputs/branch-showBranchPercentage.yaml -o %t.o
// RUN: llvm-profdata merge %S/Inputs/branch-showBranchPercentage.proftext -o %t.profdata
// RUN: llvm-cov show --show-branches=percent %t.o -instr-profile %t.profdata -path-equivalence=/tmp,%S/Inputs | FileCheck %S/Inputs/branch-showBranchPercentage.c
@@ -23,3 +24,4 @@
// HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}20.00%,{{.*}}80.00%]
// HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}0.00%,{{.*}}100.00%]
// HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}60.00%,{{.*}}40.00%]
+// HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}90.91%,{{.*}}9.09%]
diff --git a/llvm/test/tools/llvm-cov/branch-templates.test b/llvm/test/tools/llvm-cov/branch-templates.test
index 1c18356043f66f..b29e2a9d033c25 100644
--- a/llvm/test/tools/llvm-cov/branch-templates.test
+++ b/llvm/test/tools/llvm-cov/branch-templates.test
@@ -4,7 +4,7 @@
// RUN: llvm-cov report --show-branch-summary %t.o -instr-profile %t.profdata -show-functions -path-equivalence=/tmp,%S/Inputs %S/Inputs/branch-templates.cpp | FileCheck %s -check-prefix=REPORT
// RUN: llvm-cov report --show-branch-summary %t.o -instr-profile %t.profdata -path-equivalence=/tmp,%S/Inputs | FileCheck %s -check-prefix=REPORTFILE
-// REPORT: Name Regions Miss Cover Lines Miss Cover Branches Miss Cover
+// REPORT: Name Regions Miss Cover Lines Miss Cover Branches Miss Cover
// REPORT-NEXT: ---
// REPORT-NEXT: main 7 1 85.71% 10 1 90.00% 6 3 50.00%
// REPORT-NEXT: _Z4funcIiEiT_ 5 2 60.00% 7 3 57.14% 2 1 50.00%
@@ -21,8 +21,8 @@
// respectively). This is returned by: FunctionCoverageSummary::get(const
// InstantiationGroup &Group, ...)
-// REPORTFILE: Filename Regions Missed Regions Cover Functions Missed Functions Executed Lines Missed Lines Cover Branches Missed Branches Cover
+// REPORTFILE: Filename Regions Missed Regions Cover Functions Missed Functions Executed Lines Missed Lines Cover Branches Missed Branches Cover
// REPORTFILE-NEXT: ---
// REPORTFILE-NEXT: branch-templates.cpp 12 3 75.00% 2 0 100.00% 17 4 76.47% 8 4 50.00%
// REPORTFILE-NEXT: ---
-// REPORTFILE-NEXT: TOTAL 12 3 75.00% 2 0 100.00% 17 4 76.47% 8 4 50.00%
+// REPORTFILE-NEXT: TOTAL 12 3 75.00% 2 0 100.00% 17 4 76.47% 8 4 50.00%
More information about the llvm-commits
mailing list