Skip to content

Commit c6b3ade

Browse files
TheAssembler1github-actions[bot]jeanbez
authored
Fix Sphinx documentation errors and warnings (#265)
* Fix all sphinx warnings and errors. Removed repeat declarations of functions. * Committing clang-format changes * remove def of EXTENSION_MAPPING * gitignore for docs and fix c structs * Committing clang-format changes --------- Co-authored-by: github-actions <github-actions[bot]@users.noreply.github.com> Co-authored-by: Jean Luca Bez <jlbez@lbl.gov>
1 parent ebac866 commit c6b3ade

File tree

12 files changed

+462
-463
lines changed

12 files changed

+462
-463
lines changed

docs/.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
_build
2+
html

docs/source/Doxyfile.in

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2237,7 +2237,7 @@ PERLMOD_MAKEVAR_PREFIX =
22372237
# C-preprocessor directives found in the sources and include files.
22382238
# The default value is: YES.
22392239

2240-
ENABLE_PREPROCESSING = NO
2240+
ENABLE_PREPROCESSING = YES
22412241

22422242
# If the MACRO_EXPANSION tag is set to YES, doxygen will expand all macro names
22432243
# in the source code. If set to NO, only conditional compilation will be
@@ -2246,7 +2246,7 @@ ENABLE_PREPROCESSING = NO
22462246
# The default value is: NO.
22472247
# This tag requires that the tag ENABLE_PREPROCESSING is set to YES.
22482248

2249-
MACRO_EXPANSION = NO
2249+
MACRO_EXPANSION = YES
22502250

22512251
# If the EXPAND_ONLY_PREDEF and MACRO_EXPANSION tags are both set to YES then
22522252
# the macro expansion is limited to the macros specified with the PREDEFINED and
@@ -2287,7 +2287,9 @@ INCLUDE_FILE_PATTERNS =
22872287
# recursively expanded use the := operator instead of the = operator.
22882288
# This tag requires that the tag ENABLE_PREPROCESSING is set to YES.
22892289

2290-
PREDEFINED =
2290+
PREDEFINED += ATTRIBUTE(x)=
2291+
PREDEFINED += __attribute__(x)=
2292+
PREDEFINED += __attribute__=
22912293

22922294
# If the MACRO_EXPANSION and EXPAND_ONLY_PREDEF tags are set to YES then this
22932295
# tag can be used to specify a list of macro names that should be expanded. The

docs/source/api.rst

Lines changed: 441 additions & 431 deletions
Large diffs are not rendered by default.

docs/source/assumptions.rst

Lines changed: 0 additions & 3 deletions
This file was deleted.

docs/source/definitions.rst

Lines changed: 0 additions & 3 deletions
This file was deleted.

docs/source/developer-notes.rst

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ The following macros are defined in the header file `src/commons/logging/include
1111
The available macros, which follow a similar usage to `printf`, are:
1212

1313
.. code-block:: C
14+
1415
LOG_ERROR
1516
LOG_WARNING
1617
LOG_INFO
@@ -20,6 +21,7 @@ The available macros, which follow a similar usage to `printf`, are:
2021
Each of these macros automatically prepends a timestamp and log level prefix to the output:
2122

2223
.. code-block:: C
24+
2325
[year-month-day hour:minute:second] [ERROR]
2426
[year-month-day hour:minute:second] [WARNING]
2527
[year-month-day hour:minute:second] [INFO]
@@ -429,6 +431,7 @@ How to set up code formatter for PDC on Mac?
429431
3. Then follow instruction here to install clang-format: https://clang.llvm.org/get_started.html. I would suggest you do the following (suppose if you already have homebrew installed)
430432

431433
.. code-block:: Bash
434+
432435
cd $LLVM_SRC_ROOT
433436
mkdir build
434437
cd build
@@ -441,6 +444,7 @@ How to set up code formatter for PDC on Mac?
441444
4. To format all your source code, do the following
442445

443446
.. code-block:: Bash
447+
444448
cd pdc
445449
clang-format-v10 -i -style=file src/*
446450
find src -iname *.h -o -iname *.c | xargs clang-format-v10 -i -style=file
@@ -483,6 +487,7 @@ When calling your bridging functions, the best example you can follow is `src/te
483487
Remember, you must include all your bridging function calls inside the following code blocks, so that the process can have its own Julia runtime loaded.
484488

485489
.. code-block:: C
490+
486491
jl_module_list_t modules = {.julia_modules = (char *[]){JULIA_HELPER_NAME}, .num_modules = 1};
487492
init_julia(&modules);
488493
......
@@ -505,6 +510,7 @@ We provide docker support for PDC on such purpose.
505510
To build the docker image, you can run the following command in the root directory of PDC project:
506511

507512
.. code-block:: Bash
513+
508514
.docker/run_dev_base.sh
509515
510516
This will mount your PDC project directory to `/workspaces/pdc` directory in the docker container and an initial step will be performed once you attach to the container.
@@ -533,13 +539,15 @@ We currently only support to architectures, amd64 and arm64v8.
533539
To build the architecture-specific docker image on the machine with specific CPU architecture, you can run the following command in the root directory of PDC project:
534540

535541
.. code-block:: Bash
542+
536543
.docker/publish_dev_base.sh <docker_registry_namespace> <version>
537544
538545
If you run the above command on an ARM64v8 CPU (say, Apple Silicon Mac), it will generate an image named '<docker_registry_namespace>/pdc_dev_base:<version>-arm64v8'.
539546
If you run the above command on any Intel X64/AMD x64 CPU (say, Microsoft surface or Apple Intel Mac, or an Intel CPU VM from AWS/Azure/GCP/OCI), it will generate an image named '<docker_registry_namespace>/pdc_dev_base:<version>-amd64'.
540547
Once the above is done, you can pick the image build machine with fastest network and run the following
541548

542549
.. code-block:: Bash
550+
543551
.docker/publish_dev_base.sh <docker_registry_namespace> <version> 1
544552
545553
This will create a multi-arch image with both amd64 and arm64v8 architectures in your registry under your namespace.
@@ -565,11 +573,13 @@ Debugging PDC on Perlmutter with LinaroForge
565573
First, you need to start an interactive session on Perlmutter:
566574

567575
.. code-block:: Bash
576+
568577
salloc -N 1 -C cpu -q interactive -t 1:00:00
569578
570579
Then, you can load the ``forge`` module:
571580

572581
.. code-block:: Bash
582+
573583
module load forge
574584
module list
575585
@@ -582,19 +592,22 @@ Go to this website https://www.linaroforge.com/download-documentation and find t
582592
To run a test, let's lunch pdc_server with 4 cores:
583593

584594
.. code-block:: Bash
595+
585596
cd $PDC_HOME/build
586597
rm -rf ./pdc_tmp # optional if you need to clean up the PDC tmp directory
587598
srun -N 1 -n 4 -c 2 --mem=25600 --cpu_bind=cores ./bin/pdc_server.exe &
588599
589600
To debug the client, you can run the following command:
590601

591602
.. code-block:: Bash
603+
592604
cd $PDC_HOME/build
593605
ddt --connect srun -N 1 -n 4 -c 2 --mem=25600 --cpu_bind=cores ./bin/pdc_client.exe
594606
595607
But if you need to debug the server, you can prepend ``srun`` with ``ddt --connect``:
596608

597609
.. code-block:: Bash
610+
598611
cd $PDC_HOME/build
599612
rm -rf ./pdc_tmp # optional if you need to clean up the PDC tmp directory
600613
ddt --connect srun -N 1 -n 4 -c 2 --mem=25600 --cpu_bind=cores ./bin/pdc_server.exe &

docs/source/examples.rst

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@ Usage:
1616
./mpi_test.sh ./pdc_client_application MPIRUN_CMD number_of_servers number_of_clients arg1 arg2 ....
1717
./run_multiple_test.sh ./pdc_client_application_1 ./pdc_client_application_2 ......
1818
19-
2019
---------------------------
2120
PDC Hello World
2221
---------------------------
@@ -42,7 +41,6 @@ PDC Hello World
4241
* The above command will start a server with 2 processes. Then it will start the application program with 4 processes. Finally, all servers are closed.
4342
* On supercomputers, "mpiexec" can be replaced with "srun", "jsrun" or "aprun".
4443

45-
4644
---------------------------
4745
Simple I-O
4846
---------------------------
@@ -58,7 +56,6 @@ Simple I-O
5856
./run_test.sh ./obj_get_data
5957
./mpi_test.sh ./obj_get_data mpiexec 2 4
6058
61-
6259
---------------------------
6360
I-O with region mapping
6461
---------------------------
@@ -76,7 +73,6 @@ I-O with region mapping
7673
./run_test.sh ./region_obj_map_3D
7774
./mpi_test.sh ./region_obj_map_3D mpiexec 2 4
7875
79-
8076
---------------------------
8177
VPIC-IO and BD-CATS-IO
8278
---------------------------
@@ -89,7 +85,6 @@ VPIC-IO and BD-CATS-IO
8985
9086
./run_multiple_test.sh ./vpicio ./bdcats
9187
92-
9388
* VPIC-IO:
9489
* vpicio.c
9590
* VPIC I/O is an example for writing multiple objects using PDC, where each object is a variable of particles.
@@ -108,15 +103,13 @@ VPIC-IO and BD-CATS-IO
108103
HACC-IO
109104
---------------------------
110105

111-
112106
* The purpose of this benchmark is to evaluate the performance of the I/O system for the Hardware Accelerated Cosmology Code (HACC) simulation. The HACC framework uses N-body techniques to simulate the formation of structure in collisionless fluids under the influence of gravity in an expanding universe.
113107
* Each MPI rank writes 9 variables (with different data types) per particle for a total of 38 bytes.
114108

115109
.. code-block:: Bash
116110
117111
./mpi_test.sh ./haccio mpiexec 1 num-procs num-particles
118112
119-
120113
---------------------------
121114
Tile-IO
122115
---------------------------

docs/source/futurework.rst

Lines changed: 0 additions & 3 deletions
This file was deleted.

docs/source/index.rst

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -19,26 +19,22 @@ Byna, Suren, Dong, Bin, Tang, Houjun, Koziol, Quincey, Mu, Jingqing, Soumagne, J
1919
:caption: Getting Started
2020

2121
getting_started
22-
.. definitions
23-
.. assumptions
2422

2523
.. toctree::
2624
:maxdepth: 2
2725
:caption: Overview
2826

2927
introduction
3028
hdf5vol
31-
.. performance
3229

3330
.. toctree::
3431
:maxdepth: 2
3532
:caption: Resources
3633

3734
hellopdcexample
35+
examples
3836
api
3937
tools
40-
.. inflightanalysis
41-
.. futurework
4238

4339

4440
.. toctree::

docs/source/inflightanalysis.rst

Lines changed: 0 additions & 3 deletions
This file was deleted.

0 commit comments

Comments
 (0)