<html xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns="http://www.w3.org/TR/REC-html40">

<head>
<meta http-equiv=Content-Type content="text/html; charset=us-ascii">
<meta name=Generator content="Microsoft Word 11 (filtered medium)">
<style>
<!--
 /* Style Definitions */
 p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman";}
a:link, span.MsoHyperlink
        {color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {color:purple;
        text-decoration:underline;}
span.EmailStyle17
        {mso-style-type:personal-compose;
        font-family:Arial;
        color:windowtext;}
@page Section1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.Section1
        {page:Section1;}
-->
</style>

</head>

<body lang=EN-US link=blue vlink=purple>

<div class=Section1>

<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'>Hi all. A company I’m working for is interested in
using LLVM as a part of a larger suite of products, and I’m in charge of
porting it to Sun Studio 8, one of the compilers that our product builds on. I’ve
made reasonable progress, and for the most part the compiler’s
co-operating, however I’m running into a problem I believe is with
template resolution, and I’m looking for any input on where the problem
might be.<o:p></o:p></span></font></p>

<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'><o:p> </o:p></span></font></p>

<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'>When compiling LoadValueNumbering.cpp, I get the following
errors:<o:p></o:p></span></font></p>

<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'>"~/bin/../src/include/llvm/Support/Casting.h",
line 51: Error: Could not find a match for llvm::AllocationInst::classof(const
llvm::ilist_iterator<llvm::Instruction>*).<o:p></o:p></span></font></p>

<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'>"~/bin/../src/include/llvm/Support/Casting.h",
line 68:     Where: While instantiating "llvm::isa_impl<llvm::AllocationInst,
llvm::ilist_iterator<llvm::Instruction>>(const
llvm::ilist_iterator<llvm::Instruction>&)".<o:p></o:p></span></font></p>

<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'>"~/bin/../src/include/llvm/Support/Casting.h",
line 68:     Where: Instantiated from non-template code.<o:p></o:p></span></font></p>

<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'><o:p> </o:p></span></font></p>

<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'>This seems to be linked with line 364 in
LoadValueNumbering.cpp, and my best guess is that the template struct
simplify_type in ilist isn’t being picked up for some reason, so classof
gets an ilist_iterator as an argument rather than the object the iterator
points to. It happens every time I try to dyn_cast<…>(I) where I is
an ilist_iterator, but in other cases I got around it by manually retrieving
the iterator’s value with dyn_cast<…>(&*I). On line 364
this technique doesn’t work.<o:p></o:p></span></font></p>

<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'><o:p> </o:p></span></font></p>

<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'>~Michael<o:p></o:p></span></font></p>

<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'><o:p> </o:p></span></font></p>

<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'>P.S. Once I’m done with the port, I’d be happy
to check in a version on your cvs if the project is interested.<o:p></o:p></span></font></p>

</div>

</body>

</html>