From 2ac7ee7139a0a06526126d18e549c724b96e3ee8 Mon Sep 17 00:00:00 2001 From: Hongbin Zheng Date: Sat, 20 Feb 2016 03:40:19 +0000 Subject: [PATCH] Add more isl object printing functions llvm-svn: 261402 --- polly/include/polly/Support/GICHelper.h | 8 ++++++++ polly/lib/Support/GICHelper.cpp | 5 +++++ 2 files changed, 13 insertions(+) diff --git a/polly/include/polly/Support/GICHelper.h b/polly/include/polly/Support/GICHelper.h index 4471a74..87f644c 100644 --- a/polly/include/polly/Support/GICHelper.h +++ b/polly/include/polly/Support/GICHelper.h @@ -26,6 +26,7 @@ struct isl_union_set; struct isl_schedule; struct isl_multi_aff; struct isl_pw_multi_aff; +struct isl_union_pw_multi_aff; struct isl_aff; struct isl_pw_aff; struct isl_val; @@ -49,6 +50,7 @@ std::string stringFromIslObj(__isl_keep isl_union_set *uset); std::string stringFromIslObj(__isl_keep isl_schedule *schedule); std::string stringFromIslObj(__isl_keep isl_multi_aff *maff); std::string stringFromIslObj(__isl_keep isl_pw_multi_aff *pma); +std::string stringFromIslObj(__isl_keep isl_union_pw_multi_aff *upma); std::string stringFromIslObj(__isl_keep isl_aff *aff); std::string stringFromIslObj(__isl_keep isl_pw_aff *pwaff); std::string stringFromIslObj(__isl_keep isl_space *space); @@ -91,6 +93,12 @@ inline llvm::raw_ostream &operator<<(llvm::raw_ostream &OS, } inline llvm::raw_ostream &operator<<(llvm::raw_ostream &OS, + __isl_keep isl_union_pw_multi_aff *UPMA) { + OS << polly::stringFromIslObj(UPMA); + return OS; +} + +inline llvm::raw_ostream &operator<<(llvm::raw_ostream &OS, __isl_keep isl_schedule *Schedule) { OS << polly::stringFromIslObj(Schedule); return OS; diff --git a/polly/lib/Support/GICHelper.cpp b/polly/lib/Support/GICHelper.cpp index e92ea39..572904d 100644 --- a/polly/lib/Support/GICHelper.cpp +++ b/polly/lib/Support/GICHelper.cpp @@ -120,6 +120,11 @@ std::string polly::stringFromIslObj(__isl_keep isl_pw_multi_aff *pma) { isl_printer_print_pw_multi_aff); } +std::string polly::stringFromIslObj(__isl_keep isl_union_pw_multi_aff *upma) { + return stringFromIslObjInternal(upma, isl_union_pw_multi_aff_get_ctx, + isl_printer_print_union_pw_multi_aff); +} + std::string polly::stringFromIslObj(__isl_keep isl_aff *aff) { return stringFromIslObjInternal(aff, isl_aff_get_ctx, isl_printer_print_aff); } -- 2.7.4