[NFC] Make ScheduleTreeOptimizer::optimizeBand return a schedule node optimized

with optimizeMatMulPattern

This patch makes ScheduleTreeOptimizer::optimizeBand return a schedule node
optimized with optimizeMatMulPattern. Otherwise, it could not use the isolate
option, because standardBandOpts could try to tile a band node with anchored
subtree and get the error, since the use of the isolate option causes any tree
containing the node to be considered anchored. Furthermore, it is not intended
to apply standard optimizations, when the matrix multiplication has been
detected.

llvm-svn: 294444
This commit is contained in:
Roman Gareev 2017-02-08 13:29:06 +00:00
parent 2c0feec699
commit 772498dc68
3 changed files with 1 additions and 7 deletions

View File

@ -1179,7 +1179,7 @@ ScheduleTreeOptimizer::optimizeBand(__isl_take isl_schedule_node *Node,
MatMulInfoTy MMI;
if (PMBasedOpts && User && isMatrMultPattern(Node, OAI->D, MMI)) {
DEBUG(dbgs() << "The matrix multiplication pattern was detected\n");
Node = optimizeMatMulPattern(Node, OAI->TTI, MMI);
return optimizeMatMulPattern(Node, OAI->TTI, MMI);
}
return standardBandOpts(Node, User);

View File

@ -42,8 +42,6 @@
; CHECK-NEXT: for (int c4 = 0; c4 <= 23; c4 += 1)
; CHECK-NEXT: for (int c5 = 0; c5 <= min(255, -256 * c1 + 1022); c5 += 1) {
; CHECK-NEXT: // Register tiling - Points
; CHECK-NEXT: // 1st level tiling - Tiles
; CHECK-NEXT: // 1st level tiling - Points
; CHECK-NEXT: {
; CHECK-NEXT: Stmt_Copy_0(96 * c2 + 4 * c4, 8 * c3, 256 * c1 + c5);
; CHECK-NEXT: Stmt_Copy_0(96 * c2 + 4 * c4, 8 * c3 + 1, 256 * c1 + c5);

View File

@ -38,8 +38,6 @@
; CHECK-NEXT: for (int c1 = 0; c1 <= 263; c1 += 1)
; CHECK-NEXT: for (int c2 = 0; c2 <= 1023; c2 += 1) {
; CHECK-NEXT: // Register tiling - Points
; CHECK-NEXT: // 1st level tiling - Tiles
; CHECK-NEXT: // 1st level tiling - Points
; CHECK-NEXT: {
; CHECK-NEXT: Stmt_Copy_0(4 * c1, 8 * c0, c2);
; CHECK-NEXT: Stmt_Copy_0(4 * c1, 8 * c0 + 1, c2);
@ -101,8 +99,6 @@
; EXTRACTION-OF-MACRO-KERNEL-NEXT: for (int c4 = 0; c4 <= 23; c4 += 1)
; EXTRACTION-OF-MACRO-KERNEL-NEXT: for (int c5 = 0; c5 <= 255; c5 += 1) {
; EXTRACTION-OF-MACRO-KERNEL-NEXT: // Register tiling - Points
; EXTRACTION-OF-MACRO-KERNEL-NEXT: // 1st level tiling - Tiles
; EXTRACTION-OF-MACRO-KERNEL-NEXT: // 1st level tiling - Points
; EXTRACTION-OF-MACRO-KERNEL-NEXT: {
; EXTRACTION-OF-MACRO-KERNEL-NEXT: Stmt_Copy_0(96 * c2 + 4 * c4, 8 * c3, 256 * c1 + c5);
; EXTRACTION-OF-MACRO-KERNEL-NEXT: Stmt_Copy_0(96 * c2 + 4 * c4, 8 * c3 + 1, 256 * c1 + c5);