Changeset View
Changeset View
Standalone View
Standalone View
llvm/test/Transforms/LoopVectorize/diag-with-hotness-info-2.ll
Show All 16 Lines | |||||
; 14 | ; 14 | ||||
; 15 void unknown(char *A, char *B, char *C, char *D, char *E, int N) { | ; 15 void unknown(char *A, char *B, char *C, char *D, char *E, int N) { | ||||
; 16 for(int i = 0; i < N; i++) { | ; 16 for(int i = 0; i < N; i++) { | ||||
; 17 A[i + 1] = A[i] + B[i]; | ; 17 A[i + 1] = A[i] + B[i]; | ||||
; 18 C[i] = D[i] * E[i]; | ; 18 C[i] = D[i] * E[i]; | ||||
; 19 } | ; 19 } | ||||
; 20 } | ; 20 } | ||||
; CHECK: remark: /tmp/s.c:2:3: loop not vectorized: unsafe dependent memory operations in loop. Use #pragma loop distribute(enable) to allow loop distribution to attempt to isolate the offending operations into a separate loop (hotness: 300) | ; CHECK: remark: /tmp/s.c:3:14: loop not vectorized: unsafe dependent memory operations in loop. Use #pragma loop distribute(enable) to allow loop distribution to attempt to isolate the offending operations into a separate loop | ||||
alban.bridonneau: This hint is a useful one, and it was added purposefully. It should remain unchanged. I would… | |||||
; CHECK: remark: /tmp/s.c:9:3: loop not vectorized: unsafe dependent memory operations in loop. Use #pragma loop distribute(enable) to allow loop distribution to attempt to isolate the offending operations into a separate loop (hotness: 5000) | ; CHECK-NEXT: Backward loop carried data dependence. Memory location is the same as accessed at /tmp/s.c:3:16 (hotness: 300) | ||||
; CHECK: remark: /tmp/s.c:16:3: loop not vectorized: unsafe dependent memory operations in loop. Use #pragma loop distribute(enable) to allow loop distribution to attempt to isolate the offending operations into a separate loop{{$}} | ; CHECK: remark: /tmp/s.c:10:14: loop not vectorized: unsafe dependent memory operations in loop. Use #pragma loop distribute(enable) to allow loop distribution to attempt to isolate the offending operations into a separate loop | ||||
; CHECK-NEXT: Backward loop carried data dependence. Memory location is the same as accessed at /tmp/s.c:10:16 (hotness: 5000) | |||||
; CHECK: remark: /tmp/s.c:17:14: loop not vectorized: unsafe dependent memory operations in loop. Use #pragma loop distribute(enable) to allow loop distribution to attempt to isolate the offending operations into a separate loop | |||||
; CHECK-NEXT: Backward loop carried data dependence. Memory location is the same as accessed at /tmp/s.c:17:16{{$}} | |||||
; ModuleID = '/tmp/s.c' | ; ModuleID = '/tmp/s.c' | ||||
source_filename = "/tmp/s.c" | source_filename = "/tmp/s.c" | ||||
target datalayout = "e-m:o-i64:64-f80:128-n8:16:32:64-S128" | target datalayout = "e-m:o-i64:64-f80:128-n8:16:32:64-S128" | ||||
; Function Attrs: norecurse nounwind ssp uwtable | ; Function Attrs: norecurse nounwind ssp uwtable | ||||
define void @cold(i8* nocapture %A, i8* nocapture readonly %B, i8* nocapture %C, i8* nocapture readonly %D, i8* nocapture readonly %E, i32 %N) local_unnamed_addr #0 !dbg !7 !prof !56 { | define void @cold(i8* nocapture %A, i8* nocapture readonly %B, i8* nocapture %C, i8* nocapture readonly %D, i8* nocapture readonly %E, i32 %N) local_unnamed_addr #0 !dbg !7 !prof !56 { | ||||
entry: | entry: | ||||
▲ Show 20 Lines • Show All 165 Lines • Show Last 20 Lines |
This hint is a useful one, and it was added purposefully. It should remain unchanged. I would suggest that you add a case in elaborateMemoryReport to recreate this hint.