[llvm-bugs] [Bug 36120] New: IR PGO Instr generation error for comdat + MSVC triple

via llvm-bugs llvm-bugs at lists.llvm.org
Sat Jan 27 08:36:25 PST 2018


https://bugs.llvm.org/show_bug.cgi?id=36120

            Bug ID: 36120
           Summary: IR PGO Instr generation error for comdat + MSVC triple
           Product: libraries
           Version: trunk
          Hardware: PC
                OS: All
            Status: NEW
          Severity: normal
          Priority: P
         Component: Miscellaneous Instrumentation passes
          Assignee: unassignedbugs at nondot.org
          Reporter: jbc.engelen at gmail.com
                CC: llvm-bugs at lists.llvm.org

Testcase:
```
; File: irpgo.ll
target datalayout = "e-m:w-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-windows-msvc"

$_D4main3fooFZi = comdat any

define i32 @_D4main3fooFZi() #0 comdat {
  ret i32 42
}

attributes #0 = { uwtable }
```

Opt errors when generating IR PGO instrumentation:

`opt -pgo-instr-gen -instrprof -verify irpgo.ll -S`

The reported error is:
```
comdat global value has private linkage
[1 x i64]* @__profc__D4main3fooFZi
LLVM ERROR: Broken module found, compilation aborted!
```

Tested with LLVM 6.0.0 and LLVM trunk

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20180127/91855a62/attachment.html>


More information about the llvm-bugs mailing list