[PATCH] D38198: [Polly][Support] Force instatiation of isl dump() methods. NFC.

Michael Kruse via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Sep 28 02:52:47 PDT 2017


This revision was automatically updated to reflect the committed changes.
Closed by commit rL314395: [Support] Force instantiation of isl dump() methods. NFC. (authored by Meinersbur).

Changed prior to commit:
  https://reviews.llvm.org/D38198?vs=116416&id=116953#toc

Repository:
  rL LLVM

https://reviews.llvm.org/D38198

Files:
  polly/trunk/lib/Support/GICHelper.cpp


Index: polly/trunk/lib/Support/GICHelper.cpp
===================================================================
--- polly/trunk/lib/Support/GICHelper.cpp
+++ polly/trunk/lib/Support/GICHelper.cpp
@@ -223,3 +223,60 @@
 
   return getIslCompatibleName(Prefix, ValStr, Suffix);
 }
+
+#if !defined(NDEBUG) || defined(LLVM_ENABLE_DUMP)
+/// To call a inline dump() method in a debugger, at it must have been
+/// instantiated in at least one translation unit. Because isl's dump() method
+/// are meant to be called from a debugger only, but not from code, no such
+/// instantiation would exist. We use this method to force an instantiation in
+/// this translation unit. Because it has non-static linking, the compiler does
+/// not know that it is never called, and therefore must ensure the existence of
+/// the dump functions.
+void neverCalled() {
+  isl::aff().dump();
+  isl::aff_list().dump();
+  isl::ast_expr().dump();
+  isl::ast_expr_list().dump();
+  isl::ast_node().dump();
+  isl::ast_node_list().dump();
+  isl::band_list().dump();
+  isl::basic_map().dump();
+  isl::basic_map_list().dump();
+  isl::basic_set().dump();
+  isl::basic_set_list().dump();
+  isl::constraint().dump();
+  isl::constraint_list().dump();
+  isl::id().dump();
+  isl::id_list().dump();
+  isl::id_to_ast_expr().dump();
+  isl::local_space().dump();
+  isl::map().dump();
+  isl::map_list().dump();
+  isl::multi_aff().dump();
+  isl::multi_pw_aff().dump();
+  isl::multi_union_pw_aff().dump();
+  isl::multi_val().dump();
+  isl::point().dump();
+  isl::pw_aff().dump();
+  isl::pw_aff_list().dump();
+  isl::pw_multi_aff().dump();
+  isl::pw_qpolynomial().dump();
+  isl::qpolynomial().dump();
+  isl::schedule().dump();
+  isl::schedule_constraints().dump();
+  isl::schedule_node().dump();
+  isl::set().dump();
+  isl::set_list().dump();
+  isl::space().dump();
+  isl::union_map().dump();
+  isl::union_map_list().dump();
+  isl::union_pw_aff().dump();
+  isl::union_pw_aff_list().dump();
+  isl::union_pw_multi_aff().dump();
+  isl::union_pw_multi_aff_list().dump();
+  isl::union_set().dump();
+  isl::union_set_list().dump();
+  isl::val().dump();
+  isl::val_list().dump();
+}
+#endif


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D38198.116953.patch
Type: text/x-patch
Size: 2186 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20170928/94083a57/attachment.bin>


More information about the llvm-commits mailing list