<html>
<head>
<base href="https://bugs.llvm.org/">
</head>
<body><table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Bug ID</th>
<td><a class="bz_bug_link
bz_status_NEW "
title="NEW - [ARM] Hitting compiler assert with function specialization in benchmark spec2017/gcc"
href="https://bugs.llvm.org/show_bug.cgi?id=51959">51959</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>[ARM] Hitting compiler assert with function specialization in benchmark spec2017/gcc
</td>
</tr>
<tr>
<th>Product</th>
<td>new-bugs
</td>
</tr>
<tr>
<th>Version</th>
<td>trunk
</td>
</tr>
<tr>
<th>Hardware</th>
<td>PC
</td>
</tr>
<tr>
<th>OS</th>
<td>Linux
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>normal
</td>
</tr>
<tr>
<th>Priority</th>
<td>P
</td>
</tr>
<tr>
<th>Component</th>
<td>new bugs
</td>
</tr>
<tr>
<th>Assignee</th>
<td>unassignedbugs@nondot.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>steplong@quicinc.com
</td>
</tr>
<tr>
<th>CC</th>
<td>htmldeveloper@gmail.com, llvm-bugs@lists.llvm.org
</td>
</tr></table>
<p>
<div>
<pre>I'm cross compiling spec2017/gcc for ARM with -O3 -flto and passing
-plugin-opt=-enable-function-specialization to ld.lld.
ld.lld: llvm/lib/IR/Constants.cpp:867: static llvm::Constant
*llvm::ConstantInt::getTrue(llvm::Type *): Assertion `Ty->isIntOrIntVectorTy(1)
&& "Type not i1 or vector of i1."' failed.
#8 llvm::Type::getContainedType(unsigned int) const
#9 llvm::Type::getScalarType() const
#10 llvm::Type::isIntOrIntVectorTy(unsigned int) const
#11 llvm::ConstantInt::getTrue(llvm::Type*)
#12 llvm::PredicateBase::getConstraint() const
#13 llvm::optional_detail::OptionalStorage<llvm::PredicateConstraint,
true>::hasValue() const
#14 llvm::Optional<llvm::PredicateConstraint>::hasValue() const
#15 llvm::Optional<llvm::PredicateConstraint>::operator bool() const
#16 llvm::SCCPInstVisitor::handleCallResult(llvm::CallBase&)
#17 llvm::SCCPInstVisitor::visitCallBase(llvm::CallBase&)
#18 llvm::SCCPInstVisitor::visitCallInst(llvm::CallInst&)
#19 llvm::InstVisitor<llvm::SCCPInstVisitor,
void>::visitIntrinsicInst(llvm::IntrinsicInst&)
#20 llvm::InstVisitor<llvm::SCCPInstVisitor,
void>::delegateCallInst(llvm::CallInst&)
#21 FunctionSpecializer::tryToReplaceWithConstant(llvm::Value*)
#22 auto llvm::runFunctionSpecialization(llvm::Module&, llvm::DataLayout
const&, std::__1::function<llvm::TargetLibraryInfo& (llvm::Function&)>,
std::__1::function<llvm::TargetTransformInfo& (llvm::Function&)>,
std::__1::function<llvm::AssumptionCache& (llvm::Function&)>,
llvm::function_ref<llvm::AnalysisResultsForFn
(llvm::Function&)>)::$_0::operator()<llvm::SmallVector<llvm::Function*, 16u>
<span class="quote">>(llvm::SmallVector<llvm::Function*, 16u>&) const</span >
#23 llvm::runFunctionSpecialization(llvm::Module&, llvm::DataLayout const&,
std::__1::function<llvm::TargetLibraryInfo& (llvm::Function&)>,
std::__1::function<llvm::TargetTransformInfo& (llvm::Function&)>,
std::__1::function<llvm::AssumptionCache& (llvm::Function&)>,
llvm::function_ref<llvm::AnalysisResultsForFn (llvm::Function&)>)
#24 llvm::FunctionSpecializationPass::run(llvm::Module&,
llvm::AnalysisManager<llvm::Module>&)
#25 llvm::detail::PassModel<llvm::Module, llvm::FunctionSpecializationPass,
llvm::PreservedAnalyses, llvm::AnalysisManager<llvm::Module>
<span class="quote">>::run(llvm::Module&, llvm::AnalysisManager<llvm::Module>&)</span >
#26 llvm::SmallPtrSet<void*, 2u>::operator=(llvm::SmallPtrSet<void*, 2u>&&)
#27 llvm::PreservedAnalyses::operator=(llvm::PreservedAnalyses&&)
#28 llvm::PassManager<llvm::Module, llvm::AnalysisManager<llvm::Module>
<span class="quote">>::run(llvm::Module&, llvm::AnalysisManager<llvm::Module>&)</span >
#29 llvm::SmallPtrSetImplBase::isSmall() const
#30 llvm::SmallPtrSetImplBase::~SmallPtrSetImplBase()
#31 llvm::PreservedAnalyses::~PreservedAnalyses()
#32 runNewPMPasses(llvm::lto::Config const&, llvm::Module&,
llvm::TargetMachine*, unsigned int, bool, llvm::ModuleSummaryIndex*,
llvm::ModuleSummaryIndex const*)
#33 llvm::lto::opt(llvm::lto::Config const&, llvm::TargetMachine*, unsigned
int, llvm::Module&, bool, llvm::ModuleSummaryIndex*, llvm::ModuleSummaryIndex
const*, std::__1::vector<unsigned char, std::__1::allocator<unsigned char> >
const&)
#34 llvm::lto::backend(llvm::lto::Config const&,
std::__1::function<std::__1::unique_ptr<llvm::lto::NativeObjectStream,
std::__1::default_delete<llvm::lto::NativeObjectStream> > (unsigned int)>,
unsigned int, llvm::Module&, llvm::ModuleSummaryIndex&)
#35 std::__1::function<std::__1::unique_ptr<llvm::lto::NativeObjectStream,
std::__1::default_delete<llvm::lto::NativeObjectStream> > (unsigned
int)>::~function()
#36
llvm::lto::LTO::runRegularLTO(std::__1::function<std::__1::unique_ptr<llvm::lto::NativeObjectStream,
std::__1::default_delete<llvm::lto::NativeObjectStream> > (unsigned int)>)
#37 std::__1::function<std::__1::unique_ptr<llvm::lto::NativeObjectStream,
std::__1::default_delete<llvm::lto::NativeObjectStream> > (unsigned
int)>::~function()
#38
llvm::lto::LTO::run(std::__1::function<std::__1::unique_ptr<llvm::lto::NativeObjectStream,
std::__1::default_delete<llvm::lto::NativeObjectStream> > (unsigned int)>,
std::__1::function<std::__1::function<std::__1::unique_ptr<llvm::lto::NativeObjectStream,
std::__1::default_delete<llvm::lto::NativeObjectStream> > (unsigned int)>
(unsigned int, llvm::StringRef)>)
#39 lld::elf::BitcodeCompiler::compile()
#40 std::__1::vector<lld::elf::InputFile*,
std::__1::allocator<lld::elf::InputFile*> >::begin()
#41 void
lld::elf::LinkerDriver::compileBitcodeFiles<llvm::object::ELFType<(llvm::support::endianness)1,
true> >()
#42 bool llvm::opt::ArgList::hasArg<lld::elf::$_3>(lld::elf::$_3) const
#43 void
lld::elf::LinkerDriver::link<llvm::object::ELFType<(llvm::support::endianness)1,
true> >(llvm::opt::InputArgList&)
#44 lld::elf::LinkerDriver::linkerMain(llvm::ArrayRef<char const*>)
#45 lld::errorCount()
#46 lld::elf::link(llvm::ArrayRef<char const*>, bool, llvm::raw_ostream&,
llvm::raw_ostream&)
#47 lldMain(int, char const**, llvm::raw_ostream&, llvm::raw_ostream&, bool)
#48 main
#49 __libc_start_main
#50 _start</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are on the CC list for the bug.</li>
</ul>
</body>
</html>