You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Refactor the pass to only support IntrinsicInst calls.
ReplaceWithVecLib used to support instructions, as AArch64 was using this
pass to replace a vectorized frem instruction to the fmod vector library
call (through TLI).
As this replacement is now done by the codegen (#83859), there is no need
for this pass to support instructions.
Additionally, removed 'frem' tests from:
- AArch64/replace-with-veclib-armpl.ll
- AArch64/replace-with-veclib-sleef-scalable.ll
- AArch64/replace-with-veclib-sleef.l
Such testing is done at codegen level:
- #83859
define <2 x double> @llvm_cos_f64(<2 x double> %in) {
21
21
; CHECK-LABEL: define <2 x double> @llvm_cos_f64
@@ -424,47 +424,6 @@ define <vscale x 4 x float> @llvm_sin_vscale_f32(<vscale x 4 x float> %in) #0 {
424
424
ret <vscale x 4 x float> %1
425
425
}
426
426
427
-
428
-
define <2 x double> @frem_f64(<2 x double> %in) {
429
-
; CHECK-LABEL: define <2 x double> @frem_f64
430
-
; CHECK-SAME: (<2 x double> [[IN:%.*]]) {
431
-
; CHECK-NEXT: [[TMP1:%.*]] = call <2 x double> @armpl_vfmodq_f64(<2 x double> [[IN]], <2 x double> [[IN]])
432
-
; CHECK-NEXT: ret <2 x double> [[TMP1]]
433
-
;
434
-
%1= frem <2 x double> %in, %in
435
-
ret <2 x double> %1
436
-
}
437
-
438
-
define <4 x float> @frem_f32(<4 x float> %in) {
439
-
; CHECK-LABEL: define <4 x float> @frem_f32
440
-
; CHECK-SAME: (<4 x float> [[IN:%.*]]) {
441
-
; CHECK-NEXT: [[TMP1:%.*]] = call <4 x float> @armpl_vfmodq_f32(<4 x float> [[IN]], <4 x float> [[IN]])
442
-
; CHECK-NEXT: ret <4 x float> [[TMP1]]
443
-
;
444
-
%1= frem <4 x float> %in, %in
445
-
ret <4 x float> %1
446
-
}
447
-
448
-
define <vscale x 2 x double> @frem_vscale_f64(<vscale x 2 x double> %in) #0 {
449
-
; CHECK-LABEL: define <vscale x 2 x double> @frem_vscale_f64
450
-
; CHECK-SAME: (<vscale x 2 x double> [[IN:%.*]]) #[[ATTR1]] {
451
-
; CHECK-NEXT: [[TMP1:%.*]] = call <vscale x 2 x double> @armpl_svfmod_f64_x(<vscale x 2 x double> [[IN]], <vscale x 2 x double> [[IN]], <vscale x 2 x i1> shufflevector (<vscale x 2 x i1> insertelement (<vscale x 2 x i1> poison, i1 true, i64 0), <vscale x 2 x i1> poison, <vscale x 2 x i32> zeroinitializer))
452
-
; CHECK-NEXT: ret <vscale x 2 x double> [[TMP1]]
453
-
;
454
-
%1= frem <vscale x 2 x double> %in, %in
455
-
ret <vscale x 2 x double> %1
456
-
}
457
-
458
-
define <vscale x 4 x float> @frem_vscale_f32(<vscale x 4 x float> %in) #0 {
459
-
; CHECK-LABEL: define <vscale x 4 x float> @frem_vscale_f32
460
-
; CHECK-SAME: (<vscale x 4 x float> [[IN:%.*]]) #[[ATTR1]] {
461
-
; CHECK-NEXT: [[TMP1:%.*]] = call <vscale x 4 x float> @armpl_svfmod_f32_x(<vscale x 4 x float> [[IN]], <vscale x 4 x float> [[IN]], <vscale x 4 x i1> shufflevector (<vscale x 4 x i1> insertelement (<vscale x 4 x i1> poison, i1 true, i64 0), <vscale x 4 x i1> poison, <vscale x 4 x i32> zeroinitializer))
define <vscale x 2 x double> @llvm_ceil_vscale_f64(<vscale x 2 x double> %in) {
10
10
; CHECK-LABEL: @llvm_ceil_vscale_f64(
@@ -384,24 +384,6 @@ define <vscale x 4 x float> @llvm_trunc_vscale_f32(<vscale x 4 x float> %in) {
384
384
ret <vscale x 4 x float> %1
385
385
}
386
386
387
-
define <vscale x 2 x double> @frem_f64(<vscale x 2 x double> %in) {
388
-
; CHECK-LABEL: @frem_f64(
389
-
; CHECK-NEXT: [[TMP1:%.*]] = call <vscale x 2 x double> @_ZGVsMxvv_fmod(<vscale x 2 x double> [[IN:%.*]], <vscale x 2 x double> [[IN]], <vscale x 2 x i1> shufflevector (<vscale x 2 x i1> insertelement (<vscale x 2 x i1> poison, i1 true, i64 0), <vscale x 2 x i1> poison, <vscale x 2 x i32> zeroinitializer))
390
-
; CHECK-NEXT: ret <vscale x 2 x double> [[TMP1]]
391
-
;
392
-
%1= frem <vscale x 2 x double> %in, %in
393
-
ret <vscale x 2 x double> %1
394
-
}
395
-
396
-
define <vscale x 4 x float> @frem_f32(<vscale x 4 x float> %in) {
397
-
; CHECK-LABEL: @frem_f32(
398
-
; CHECK-NEXT: [[TMP1:%.*]] = call <vscale x 4 x float> @_ZGVsMxvv_fmodf(<vscale x 4 x float> [[IN:%.*]], <vscale x 4 x float> [[IN]], <vscale x 4 x i1> shufflevector (<vscale x 4 x i1> insertelement (<vscale x 4 x i1> poison, i1 true, i64 0), <vscale x 4 x i1> poison, <vscale x 4 x i32> zeroinitializer))
399
-
; CHECK-NEXT: ret <vscale x 4 x float> [[TMP1]]
400
-
;
401
-
%1= frem <vscale x 4 x float> %in, %in
402
-
ret <vscale x 4 x float> %1
403
-
}
404
-
405
387
declare <vscale x 2 x double> @llvm.ceil.nxv2f64(<vscale x 2 x double>)
406
388
declare <vscale x 4 x float> @llvm.ceil.nxv4f32(<vscale x 4 x float>)
407
389
declare <vscale x 2 x double> @llvm.copysign.nxv2f64(<vscale x 2 x double>, <vscale x 2 x double>)
0 commit comments