Pārlūkot izejas kodu

new directory for documentating the inside of StarPU

Nathalie Furmento 6 gadi atpakaļ
vecāks
revīzija
ee0fee5f59

+ 4 - 0
configure.ac

@@ -3521,6 +3521,7 @@ AC_CONFIG_COMMANDS([executable-scripts], [
   chmod +x tools/starpu_paje_sort
   chmod +x tools/starpu_smpirun
   chmod +x doc/doxygen/doxygen_filter.sh
+  chmod +x doc/doxygen_dev/doxygen_filter.sh
   mkdir -p tests/microbenchs
   test -e tests/microbenchs/tasks_size_overhead.sh || ln -sf $ac_abs_top_srcdir/tests/microbenchs/tasks_size_overhead.sh tests/microbenchs/
   test -e tests/microbenchs/tasks_size_overhead_sched.sh || ln -sf $ac_abs_top_srcdir/tests/microbenchs/tasks_size_overhead_sched.sh tests/microbenchs/
@@ -3637,6 +3638,9 @@ AC_OUTPUT([
 	doc/doxygen/Makefile
 	doc/doxygen/doxygen-config.cfg
 	doc/doxygen/doxygen_filter.sh
+	doc/doxygen_dev/Makefile
+	doc/doxygen_dev/doxygen-config.cfg
+	doc/doxygen_dev/doxygen_filter.sh
 	tools/msvc/starpu_var.bat
 	min-dgels/Makefile
 ])

+ 3 - 1
doc/Makefile.am

@@ -1,6 +1,6 @@
 # StarPU --- Runtime system for heterogeneous multicore architectures.
 #
-# Copyright (C) 2013-2017                                CNRS
+# Copyright (C) 2013-2018                                CNRS
 # Copyright (C) 2015                                     Inria
 # Copyright (C) 2015                                     Université de Bordeaux
 #
@@ -16,7 +16,9 @@
 # See the GNU Lesser General Public License in COPYING.LGPL for more details.
 #
 SUBDIRS = doxygen
+SUBDIRS += doxygen_dev
 DIST_SUBDIRS = doxygen
+DIST_SUBDIRS += doxygen_dev
 
 EXTRA_DIST =    tutorial/hello_world.c \
 		tutorial/hello_world_plugin.c \

+ 166 - 0
doc/doxygen_dev/Makefile.am

@@ -0,0 +1,166 @@
+# StarPU --- Runtime system for heterogeneous multicore architectures.
+#
+# Copyright (C) 2013-2018                                Inria
+# Copyright (C) 2010-2018                                CNRS
+# Copyright (C) 2009,2011,2013-2014,2017                 Université de Bordeaux
+#
+# StarPU is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as published by
+# the Free Software Foundation; either version 2.1 of the License, or (at
+# your option) any later version.
+#
+# StarPU is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+#
+# See the GNU Lesser General Public License in COPYING.LGPL for more details.
+#
+DOXYGEN = doxygen
+PDFLATEX = pdflatex
+MAKEINDEX = makeindex
+
+DOX_DIR = $(top_builddir)/doc/doxygen_dev
+DOX_CONFIG = $(top_srcdir)/doc/doxygen_dev/doxygen.cfg
+
+DOX_HTML_DIR = html
+DOX_LATEX_DIR = latex
+DOX_PDF = $(DOX_DIR)/starpu.pdf
+DOX_TAG = starpu.tag
+
+txtdir   = $(docdir)/manual/dev
+
+EXTRA_DIST =
+
+if BUILD_DOC
+all: $(DOX_HTML_DIR) $(DOX_PDF)
+EXTRA_DIST += $(DOX_HTML_DIR) $(DOX_PDF)
+txt_DATA = $(DOX_PDF)
+DOX_HTML_SRCDIR=$(DOX_HTML_DIR)
+install-exec-hook:
+	$(MKDIR_P) $(DESTDIR)$(docdir)/manual/dev/html
+	(cd $(DOX_HTML_SRCDIR) && find . -type f -exec $(INSTALL) -c -m 644 {} $(DESTDIR)$(docdir)/manual/dev/html \;)
+uninstall-hook:
+	rm -rf $(DESTDIR)$(docdir)/manual/dev/html
+else
+if AVAILABLE_DOC
+EXTRA_DIST += $(top_srcdir)/doc/doxygen_dev/html $(top_srcdir)/doc/doxygen_dev/starpu.pdf
+txt_DATA = $(top_srcdir)/doc/doxygen_dev/starpu.pdf
+DOX_HTML_SRCDIR=$(top_srcdir)/doc/doxygen_dev/html
+install-exec-hook:
+	$(MKDIR_P) $(DESTDIR)$(docdir)/manual/dev/html
+	(cd $(DOX_HTML_SRCDIR) && find . -type f -exec $(INSTALL) -c -m 644 {} $(DESTDIR)$(docdir)/manual/dev/html \;)
+uninstall-hook:
+	rm -rf $(DESTDIR)$(docdir)/manual/dev/html
+endif
+endif
+
+chapters =	\
+	chapters/000_introduction.doxy
+
+images =
+
+if BUILD_DOC
+starpu_config.h: $(top_srcdir)/include/starpu_config.h.in
+	@$(SED) 's/#undef \(.*\)/#define \1 1/' $< > $@
+
+chapters/version.sty: $(chapters)
+	@for f in $(chapters) ; do \
+                if test -f $(top_srcdir)/doc/doxygen_dev/$$f ; then $(PROG_STAT) --format=%Y $(top_srcdir)/doc/doxygen_dev/$$f ; fi \
+        done | sort -r | head -1 > timestamp_sty
+	@if test -s timestamp_sty ; then \
+		LC_ALL=C $(PROG_DATE) --date=@`cat timestamp_sty` +"%d %B %Y" > timestamp_sty_updated ;\
+		LC_ALL=C $(PROG_DATE) --date=@`cat timestamp_sty` +"%B %Y" > timestamp_sty_updated_month ;\
+	fi
+	@if test -s timestamp_sty_updated ; then \
+		echo ':newcommand{:STARPUUPDATED}{'`cat timestamp_sty_updated`'}' > $(top_srcdir)/doc/doxygen_dev/chapters/version.sty;\
+	else \
+		echo ':newcommand{:STARPUUPDATED}{unknown date}' > $(top_srcdir)/doc/doxygen_dev/chapters/version.sty;\
+	fi
+	@echo ':newcommand{:STARPUVERSION}{$(VERSION)}' >> $(top_srcdir)/doc/doxygen_dev/chapters/version.sty
+	@$(SED) -i 's/:/\\/g' $(top_srcdir)/doc/doxygen_dev/chapters/version.sty
+	@for f in timestamp_sty timestamp_sty_updated timestamp_sty_updated_month ; do \
+		if test -f $$f ; then $(RM) $$f ; fi ;\
+	done
+
+chapters/version.html: $(chapters)
+	@for f in $(chapters) ; do \
+                if test -f $(top_srcdir)/doc/doxygen_dev/$$f ; then $(PROG_STAT) --format=%Y $(top_srcdir)/doc/doxygen_dev/$$f ; fi \
+        done | sort -r | head -1 > timestamp_html
+	@if test -s timestamp_html ; then \
+		LC_ALL=C $(PROG_DATE) --date=@`cat timestamp_html` +"%d %B %Y" > timestamp_html_updated ;\
+		LC_ALL=C $(PROG_DATE) --date=@`cat timestamp_html` +"%B %Y" > timestamp_html_updated_month ;\
+	fi
+	@echo "This manual documents the internal usage of StarPU version $(VERSION)." > $(top_srcdir)/doc/doxygen_dev/chapters/version.html
+	@if test -s timestamp_html_updated ; then \
+		echo "Its contents was last updated on "`cat timestamp_html_updated`"." >> $(top_srcdir)/doc/doxygen_dev/chapters/version.html;\
+	else \
+		echo "Its contents was last updated on <em>unknown_date</em>." >> $(top_srcdir)/doc/doxygen_dev/chapters/version.html;\
+	fi
+	@for f in timestamp_html timestamp_html_updated timestamp_html_updated_month ; do \
+		if test -f $$f ; then $(RM) $$f ; fi ;\
+	done
+
+
+dox_inputs = $(DOX_CONFIG) 				\
+	$(chapters) 					\
+	starpu_config.h					\
+	chapters/version.sty				\
+	chapters/version.html				\
+	$(top_srcdir)/src/core/workers.h
+
+$(DOX_TAG): $(dox_inputs)
+	@rm -fr $(DOX_HTML_DIR) $(DOX_LATEX_DIR)
+	@$(DOXYGEN) $(DOX_CONFIG)
+	@$(SED) -i 's/ModuleDocumentation <\/li>/<a class="el" href="modules.html">Modules<\/a>/' html/index.html
+	@$(SED) -i 's/FileDocumentation <\/li>/<a class="el" href="files.html">Files<\/a>/' html/index.html
+
+old:
+        # comment for the line below: what we really want to do is to remove the line, but dy doing so, it avoids opening the interactive menu when browsing files
+	@if test -f html/navtree.js ; then $(SED) -i 's/\[ "Files", "Files.html", null \]/\[ "", "Files.html", null \]/' html/navtree.js ; fi
+	@$(SED) -i 's/.*"Files.html".*//' html/pages.html
+	@if test -f latex/main.tex ; then mv latex/main.tex latex/index.tex ; fi
+	@$(SED) -i '/\\begin{titlepage}/,$$d' $(DOX_LATEX_DIR)/refman.tex
+	@cat $(top_srcdir)/doc/doxygen_dev/refman.tex >> $(DOX_LATEX_DIR)/refman.tex
+
+$(DOX_PDF): $(DOX_TAG) #refman.tex
+	@cp $(top_srcdir)/doc/doxygen_dev/chapters/version.sty $(DOX_LATEX_DIR)
+	@-cp $(top_srcdir)/doc/doxygen_dev/chapters/images/*pdf $(DOX_LATEX_DIR)
+	@echo $(PDFLATEX) $(DOX_LATEX_DIR)/refman.tex
+	@cd $(DOX_LATEX_DIR) ;\
+	rm -f *.aux *.toc *.idx *.ind *.ilg *.log *.out ;\
+	$(SED) -i -e 's/__env__/\\_Environment Variables!/' -e 's/\\-\\_\\-\\-\\_\\-env\\-\\_\\-\\-\\_\\-//' ExecutionConfigurationThroughEnvironmentVariables.tex ;\
+	$(SED) -i -e 's/__configure__/\\_Configure Options!/' -e 's/\\-\\_\\-\\-\\_\\-configure\\-\\_\\-\\-\\_\\-//' CompilationConfiguration.tex ;\
+	$(SED) -i s'/\\item Module\\-Documentation/\\item \\hyperlink{ModuleDocumentation}{Module Documentation}/' index.tex ;\
+	$(SED) -i s'/\\item File\\-Documentation/\\item \\hyperlink{FileDocumentation}{File Documentation}/' index.tex ;\
+	$(PDFLATEX) refman.tex ;\
+	$(MAKEINDEX) refman.idx ;\
+	$(PDFLATEX) refman.tex ;\
+	done=0; repeat=5 ;\
+	while test $$done = 0 -a $$repeat -gt 0; do \
+           if $(EGREP) 'Rerun (LaTeX|to get cross-references right)' refman.log > /dev/null 2>&1; then \
+	       $(PDFLATEX) refman.tex; \
+	       repeat=`expr $$repeat - 1`; \
+	   else \
+	       done=1; \
+	   fi; \
+	done
+	mv $(DOX_LATEX_DIR)/refman.pdf $(DOX_PDF)
+
+CLEANFILES = $(DOX_TAG) starpu_config.h \
+    -r \
+    $(DOX_HTML_DIR) \
+    $(DOX_LATEX_DIR) \
+    $(DOX_PDF)
+
+endif
+
+EXTRA_DIST += doxygen.cfg refman.tex \
+	      $(chapters) $(images)
+
+# Rule to update documentation on web server. Should only be used locally.
+PUBLISHHOST	?= gforge
+update-web: $(DOX_PDF)
+	scp -pr starpu.pdf html $(PUBLISHHOST):/home/groups/starpu/htdocs/doc/dev
+
+showcheck:
+	-cat /dev/null

+ 28 - 0
doc/doxygen_dev/chapters/000_introduction.doxy

@@ -0,0 +1,28 @@
+/* StarPU --- Runtime system for heterogeneous multicore architectures.
+ *
+ * Copyright (C) 2018                                     CNRS
+ *
+ * StarPU is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License as published by
+ * the Free Software Foundation; either version 2.1 of the License, or (at
+ * your option) any later version.
+ *
+ * StarPU is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+ *
+ * See the GNU Lesser General Public License in COPYING.LGPL for more details.
+ */
+
+/*! \mainpage Introduction
+
+\htmlonly
+<h1><a class="anchor" id="Foreword"></a>Foreword</h1>
+\endhtmlonly
+\htmlinclude version.html
+\htmlinclude foreword.html
+
+\section Motivation Motivation
+
+
+*/

+ 31 - 0
doc/doxygen_dev/doxygen-config.cfg.in

@@ -0,0 +1,31 @@
+# StarPU --- Runtime system for heterogeneous multicore architectures.
+#
+# Copyright (C) 2010-2018                                CNRS
+# Copyright (C) 2011-2013,2016                           Inria
+# Copyright (C) 2009-2014                                Université de Bordeaux
+# Copyright (C) 2011                                     Télécom-SudParis
+#
+# StarPU is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as published by
+# the Free Software Foundation; either version 2.1 of the License, or (at
+# your option) any later version.
+#
+# StarPU is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+#
+# See the GNU Lesser General Public License in COPYING.LGPL for more details.
+#
+INPUT                  = @top_srcdir@/doc/doxygen_dev/chapters         \
+                         @top_builddir@/doc/doxygen_dev/starpu_config.h \
+			 @top_srcdir@/src/core/workers.h
+
+EXAMPLE_PATH           = @top_srcdir@/doc/doxygen_dev \
+		       	 @top_srcdir@/doc/doxygen/chapters
+
+INPUT_FILTER           = @top_builddir@/doc/doxygen_dev/doxygen_filter.sh
+
+#LATEX_HEADER           = @top_srcdir@/doc/doxygen/refman.tex
+
+#IMAGE_PATH             = @top_srcdir@/doc/doxygen_dev/chapters/images
+

Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 1907 - 0
doc/doxygen_dev/doxygen.cfg


+ 24 - 0
doc/doxygen_dev/doxygen_filter.sh.in

@@ -0,0 +1,24 @@
+#!/bin/bash
+# StarPU --- Runtime system for heterogeneous multicore architectures.
+#
+# Copyright (C) 2013-2014,2016-2017                      CNRS
+#
+# StarPU is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as published by
+# the Free Software Foundation; either version 2.1 of the License, or (at
+# your option) any later version.
+#
+# StarPU is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+#
+# See the GNU Lesser General Public License in COPYING.LGPL for more details.
+#
+if [ "$(basename $1)" == "starpufft.h" ] ; then
+    gcc -E $1 -I @top_srcdir@/include/ -I @top_builddir@/include/ |grep -i starpufft
+else
+    # the macro STARPU_DEPRECATED needs to be removed as it is not properly processed by doxygen
+    # lines starting with // in the doxygen input files are considered as comments to be removed
+    sed -e 's/STARPU_DEPRECATED//' $1 | sed 's/^\/\/.*//'
+fi
+

+ 20 - 0
doc/doxygen_dev/foreword.html

@@ -0,0 +1,20 @@
+<br/>
+<br/>
+Copyright &copy; 2009-2018 Université de Bordeaux
+<br/>
+Copyright &copy; 2010-2018 CNRS
+<br/>
+Copyright &copy; 2011-2018 Inria
+<br/>
+<br/>
+<br/>
+
+<blockquote>
+Permission is granted to copy, distribute and/or modify this document
+under the terms of the GNU Free Documentation License, Version 1.3 or
+any later version published by the Free Software Foundation; with no
+Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. A
+copy of the license is included in the section entitled “GNU Free
+Documentation License”.
+</blockquote>
+<br/>