<div dir="ltr">Hi Rob,<div><br></div><div>I'm pretty sure this was r222040, r222265, and r224097.</div><div><br></div><div>I'd try trunk.</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Feb 11, 2015 at 8:00 PM, Rob Grapes <span dir="ltr"><<a href="mailto:Rob.Grapes@umajin.com" target="_blank">Rob.Grapes@umajin.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi,<br>
<br>
I'm hoping someone here can help me.<br>
<br>
I've just updated to LLVM 3.5.0 and when I run the following I eventually get a crash when I run out of memory.<br>
<br>
opt -O2 bug.ll<br>
<br>
I'll try 3.5.1, then if that's still fails I'll try trunk.<br>
<br>
It seems to be related to the<br>
  %5 = fptrunc double %4 to float<br>
line which is continually being added to the work list.<br>
<br>
Rob.<br>
<br>
<br>
<br>
bug.ll contains the following:<br>
<br>
; ModuleID = 'bug.u'<br>
target datalayout = "e-m:w-p:32:32-i64:64-f80:32-n8:16:32-S32"<br>
target triple = "i686-pc-windows-msvc"<br>
<br>
%string = type { i8*, i8* }<br>
%vec3 = type { float, float, float }<br>
%var = type { i32, i64 }<br>
<br>
%object = type { i8*, %string, %string, i8* }<br>
<br>
@hue = global double 0.000000e+00<br>
<br>
; Function Attrs: noinline nounwind<br>
declare double @rand__d__v() #0<br>
<br>
; Function Attrs: noinline nounwind<br>
declare %vec3* @vec3__PZ4vec3__fff(float, float, float) #0<br>
<br>
; Function Attrs: noinline nounwind<br>
define i32 @main__i__v() #0 {<br>
locals:<br>
  br label %entry<br>
<br>
entry:                                            ; preds = %locals<br>
<br>
  %0 = call double @rand__d__v() #1<br>
  store double %0, double* @hue<br>
<br>
  %1 = load double* @hue<br>
  %2 = fadd double %1, 0x3FE3C6EF372FE951<br>
  store double %2, double* @hue<br>
<br>
  %3 = load double* @hue<br>
  %4 = frem double %3, 1.000000e+00<br>
  %5 = fptrunc double %4 to float<br>
  %6 = call %vec3* @vec3__PZ4vec3__fff(float %5, float 0x3FD3333340000000, float 0x3FEE666660000000) #1<br>
<br>
  ret i32 0<br>
}<br>
<br>
attributes #0 = { noinline nounwind }<br>
attributes #1 = { nounwind }<br>
<br>
The last few lines from the log are as follows:<br>
<br>
[2015-02-12 16:48:08.678188100] 0xb81c40   Executing Pass 'Interprocedural Sparse Conditional Constant Propagation' on Module 'bug.ll'...<br>
0xb94e90     Required Analyses: Target Library Information<br>
 -*- 'Interprocedural Sparse Conditional Constant Propagation' is the last user of following pass instances. Free theseinstances<br>
[2015-02-12 16:48:08.683191600] 0xb81c40    Freeing Pass 'Interprocedural Sparse Conditional Constant Propagation' on Module 'bug.ll'...<br>
[2015-02-12 16:48:08.686193300] 0xb81c40   Executing Pass 'Global Variable Optimizer' on Module 'bug.ll'...<br>
0xb845b0     Required Analyses: Target Library Information<br>
 -*- 'Global Variable Optimizer' is the last user of following pass instances. Free these instances<br>
[2015-02-12 16:48:08.688194100] 0xb81c40    Freeing Pass 'Global Variable Optimizer' on Module 'bug.ll'...<br>
[2015-02-12 16:48:08.690195800] 0xb81c40   Executing Pass 'Dead Argument Elimination' on Module 'bug.ll'...<br>
 -*- 'Dead Argument Elimination' is the last user of following pass instances. Free these instances<br>
[2015-02-12 16:48:08.694198400] 0xb81c40    Freeing Pass 'Dead Argument Elimination' on Module 'bug.ll'...<br>
[2015-02-12 16:48:08.696202400] 0xb81c40   Executing Pass 'Function Pass Manager' on Module 'bug.ll'...<br>
[2015-02-12 16:48:08.698201000] 0xba8638     Executing Pass 'Combine redundant instructions' on Function 'main__i__v'...<br>
0xbb0fc8       Required Analyses: Target Library Information<br>
<br>_______________________________________________<br>
LLVM Developers mailing list<br>
<a href="mailto:LLVMdev@cs.uiuc.edu">LLVMdev@cs.uiuc.edu</a>         <a href="http://llvm.cs.uiuc.edu" target="_blank">http://llvm.cs.uiuc.edu</a><br>
<a href="http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev" target="_blank">http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev</a><br>
<br></blockquote></div><br></div>