[llvm] r225304 - Fix using wrong intrinsic in test

Matt Arsenault arsenm2 at gmail.com
Wed Jan 7 08:35:04 PST 2015


> On Jan 6, 2015, at 6:04 PM, Hal Finkel <hfinkel at anl.gov> wrote:
> 
> ----- Original Message -----
>> From: "Matt Arsenault" <Matthew.Arsenault at amd.com>
>> To: llvm-commits at cs.uiuc.edu
>> Sent: Tuesday, January 6, 2015 5:00:34 PM
>> Subject: [llvm] r225304 - Fix using wrong intrinsic in test
>> 
>> Author: arsenm
>> Date: Tue Jan  6 17:00:33 2015
>> New Revision: 225304
>> 
>> URL: http://llvm.org/viewvc/llvm-project?rev=225304&view=rev
>> Log:
>> Fix using wrong intrinsic in test
>> 
>> This is a leftover from renaming the intrinsic.
>> It's surprising the unknown llvm. intrinsic wasn't rejected.
> 
> More surprising, perhaps, is that the test did not fail. ;) -- Perhaps we need an improved test?
> 
> -Hal
> 

I believe the point of the test is that it doesn’t do anything, so this is OK. I think this was to make sure something like min(x, min(x, y)) didn’t accidentally accept max



>> 
>> Modified:
>>    llvm/trunk/test/Transforms/InstCombine/minnum.ll
>> 
>> Modified: llvm/trunk/test/Transforms/InstCombine/minnum.ll
>> URL:
>> http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Transforms/InstCombine/minnum.ll?rev=225304&r1=225303&r2=225304&view=diff
>> ==============================================================================
>> --- llvm/trunk/test/Transforms/InstCombine/minnum.ll (original)
>> +++ llvm/trunk/test/Transforms/InstCombine/minnum.ll Tue Jan  6
>> 17:00:33 2015
>> @@ -7,7 +7,7 @@ declare <4 x float> @llvm.minnum.v4f32(<
>> declare double @llvm.minnum.f64(double, double) #0
>> declare <2 x double> @llvm.minnum.v2f64(<2 x double>, <2 x double>)
>> #0
>> 
>> -declare float @llvm.fmax.f32(float, float) #0
>> +declare float @llvm.maxnum.f32(float, float) #0
>> 
>> ; CHECK-LABEL: @constant_fold_minnum_f32
>> ; CHECK-NEXT: ret float 1.000000e+00
>> @@ -206,23 +206,23 @@ define float @minnum4(float %x, float %y
>>   ret float %c
>> }
>> 
>> -; CHECK-LABEL: @minnum_x_fmax_x_y
>> -; CHECK-NEXT: call float @llvm.fmax.f32
>> +; CHECK-LABEL: @minnum_x_maxnum_x_y
>> +; CHECK-NEXT: call float @llvm.maxnum.f32
>> ; CHECK-NEXT: call float @llvm.minnum.f32
>> ; CHECK-NEXT: ret float
>> -define float @minnum_x_fmax_x_y(float %x, float %y) #0 {
>> -  %a = call float @llvm.fmax.f32(float %x, float %y) #0
>> +define float @minnum_x_maxnum_x_y(float %x, float %y) #0 {
>> +  %a = call float @llvm.maxnum.f32(float %x, float %y) #0
>>   %b = call float @llvm.minnum.f32(float %x, float %a) #0
>>   ret float %b
>> }
>> 
>> -; CHECK-LABEL: @fmax_x_minnum_x_y
>> +; CHECK-LABEL: @maxnum_x_minnum_x_y
>> ; CHECK-NEXT: call float @llvm.minnum.f32
>> -; CHECK-NEXT: call float @llvm.fmax.f32
>> +; CHECK-NEXT: call float @llvm.maxnum.f32
>> ; CHECK-NEXT: ret float
>> -define float @fmax_x_minnum_x_y(float %x, float %y) #0 {
>> +define float @maxnum_x_minnum_x_y(float %x, float %y) #0 {
>>   %a = call float @llvm.minnum.f32(float %x, float %y) #0
>> -  %b = call float @llvm.fmax.f32(float %x, float %a) #0
>> +  %b = call float @llvm.maxnum.f32(float %x, float %a) #0
>>   ret float %b
>> }
>> 
>> 
>> 
>> _______________________________________________
>> llvm-commits mailing list
>> llvm-commits at cs.uiuc.edu
>> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
>> 
> 
> -- 
> Hal Finkel
> Assistant Computational Scientist
> Leadership Computing Facility
> Argonne National Laboratory
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu <mailto:llvm-commits at cs.uiuc.edu>
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits <http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20150107/88f70048/attachment.html>


More information about the llvm-commits mailing list