Skip to content

Commit

Permalink
Merge branch 'master' into Remove_reserved_identifiers
Browse files Browse the repository at this point in the history
  • Loading branch information
gsjaardema authored Nov 13, 2023
2 parents 5f00f46 + 957345b commit 169e361
Show file tree
Hide file tree
Showing 26 changed files with 59 additions and 35 deletions.
7 changes: 4 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,8 @@ libraries using the `install-tpl.sh` script, or you can install them
manually as detailed in
[TPL-Manual-Install.md](TPL-Manual-Install.md).

* To use the script, simply type `./install-tpl.sh`
* The script requires bash and wget, which you may need to install.
* To use the script, simply type `bash ./install-tpl.sh`.
* The default behavior can be modified via a few environment variables:

| Variable | Values | Default | Description |
Expand Down Expand Up @@ -93,7 +94,7 @@ to configure the SEACAS CMake build.
* `cd $ACCESS`
* `mkdir build`
* `cd build`
* edit the `${ACCESS}cmake-config` file and adjust compilers and other settings as needed.
* edit the `${ACCESS}/cmake-config` file and adjust compilers and other settings as needed.
* enter the command `../cmake-config` and cmake should configure everything for the build.
* `make && make install`
* If everything works, your applications should be in `${ACCESS}/bin`
Expand Down Expand Up @@ -285,7 +286,7 @@ in aprepro.
### Mac
On a mac system, I use the `brew` system which provides all of the
applications listed above. The X11 system I use is `XQuartz`. The
Mac also requires `XCode`
Mac also requires `Xcode`

### Linux
On an ubuntu system, the following is used to set up the basic
Expand Down
4 changes: 2 additions & 2 deletions packages/seacas/applications/exodiff/check.C
Original file line number Diff line number Diff line change
Expand Up @@ -257,8 +257,8 @@ namespace {
size_t matched = 0;
for (size_t b = 0; b < file1.Num_Assembly(); ++b) {
Assembly<INT> *assembly1 = file1.Get_Assembly_by_Index(b);
Assembly<INT> *assembly2 = nullptr;
if (assembly1 != nullptr) {
Assembly<INT> *assembly2 = nullptr;
if (interFace.by_name) {
assembly2 = file2.Get_Assembly_by_Name(assembly1->Name());
}
Expand All @@ -282,8 +282,8 @@ namespace {
if (matched != file2.Num_Assembly()) {
for (size_t b = 0; b < file2.Num_Assembly(); ++b) {
Assembly<INT> *assembly2 = file2.Get_Assembly_by_Index(b);
Assembly<INT> *assembly1 = nullptr;
if (assembly2 != nullptr) {
Assembly<INT> *assembly1 = nullptr;
if (interFace.by_name) {
assembly1 = file1.Get_Assembly_by_Name(assembly2->Name());
}
Expand Down
2 changes: 2 additions & 0 deletions packages/seacas/libraries/chaco/util/bit_reverse.c
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@
* See packages/seacas/LICENSE for details
*/

#include "prototypes.h"

/* Reverse the bits of a number. */
int bit_reverse(int val, int nbits)
/* value to reverse bits of */
Expand Down
5 changes: 3 additions & 2 deletions packages/seacas/libraries/chaco/util/random.c
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,6 @@
#define R 10855L /* remainder */
#define MAX_VALUE (MOD - 1)

#define EXP_VAL 1285562981L /* value for 10,000th draw */

#define IMPOSSIBLE_RAND (-1)
#define STARTUP_RANDS \
16 /* throw away this number of \
Expand Down Expand Up @@ -135,6 +133,9 @@ double rand_rect_port(void) { return (double)rand_port() / (double)(MAX_VALUE +
use Russian peasant algorithm followed by approximate factoring */

#if defined(TESTING)

#define EXP_VAL 1285562981L /* value for 10,000th draw */

/* Test the generator */
#include <stdio.h>
int main(void)
Expand Down
2 changes: 1 addition & 1 deletion packages/seacas/libraries/exodus/include/exodusII_int.h
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ extern EX_mutex_t EX_g;
extern int exi_mutex_lock(EX_mutex_t *mutex);
extern int exi_mutex_unlock(EX_mutex_t *mutex, const char *func, int line);
extern void exi_pthread_first_thread_init(void);
extern EX_errval_t *exerrval_get();
extern EX_errval_t *exerrval_get(void);

#define EX_FUNC_ENTER() \
do { \
Expand Down
1 change: 0 additions & 1 deletion packages/seacas/libraries/ioss/src/Ioss_Compare.C
Original file line number Diff line number Diff line change
Expand Up @@ -1114,7 +1114,6 @@ namespace {
}
}
if (!found) {
name_not_found = true;
fmt::print(Ioss::WarnOut(), NOTFOUND_1, type, in_set_2->name());
overall_result = false;
}
Expand Down
1 change: 0 additions & 1 deletion packages/zoltan/siMPI/pyMPI/siMPI/PMPI_Abort.c
Original file line number Diff line number Diff line change
Expand Up @@ -24,5 +24,4 @@ int PMPI_Abort( MPI_Comm comm, int errorcode )
#endif
_MPI_ERR_ROUTINE(errorcode, "MPI aborting...");
abort();
return -1;
}
2 changes: 1 addition & 1 deletion packages/zoltan/siMPI/pyMPI/siMPI/_MPI_OP_UTIL.c
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ void _MPI_Default_Op ( void* a, void* b, int* len, MPI_Datatype* type )
}

/*==========================================================================*/
void _MPI_Ops_init(int i)
static void _MPI_Ops_init(int i)
{
_MPI_COVERAGE();
_MPI_OP_LIST[i].valid = _MPI_NOT_VALID;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -183,17 +183,17 @@ static unsigned int dd_nh2 (ZOLTAN_ID_PTR gid, int gid_length,

static int compare_sort (const void *a, const void *b)
{
if (((Range_Info*) a)->low < ((Range_Info *) b)->low) return -1;
if (((Range_Info*) a)->low > ((Range_Info *) b)->low) return 1;
if (((const Range_Info*) a)->low < ((const Range_Info *) b)->low) return -1;
if (((const Range_Info*) a)->low > ((const Range_Info *) b)->low) return 1;
else return 0 ;
}


static int compare_search (const void *a, const void *b)
{
int temp = (signed) *((ZOLTAN_ID_TYPE *) a);
if (temp < ((Range_Info*) b)->low) return -1;
if (temp > ((Range_Info*) b)->high) return 1;
int temp = (signed) *((const ZOLTAN_ID_TYPE *) a);
if (temp < ((const Range_Info*) b)->low) return -1;
if (temp > ((const Range_Info*) b)->high) return 1;
else return 0 ;
}

Expand Down
2 changes: 1 addition & 1 deletion packages/zoltan/src/coloring/g2l_hash.c
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ extern "C" {

#define MAX_PRIME 193

int Zoltan_GenPrime(int stopafter, int *prime_num)
static int Zoltan_GenPrime(int stopafter, int *prime_num)
{
static const int primes[MAX_PRIME]=
{2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 37, 41, 47, 53, 59, 67, 79, 89,
Expand Down
1 change: 1 addition & 0 deletions packages/zoltan/src/ha/divide_machine.c
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ extern "C" {


#include "zz_const.h"
#include "ha_const.h"


int Zoltan_Divide_Machine(
Expand Down
4 changes: 2 additions & 2 deletions packages/zoltan/src/hsfc/hsfc.c
Original file line number Diff line number Diff line change
Expand Up @@ -698,8 +698,8 @@ int Zoltan_HSFC(
/* routine for bsearch locating the partition segment holding key */
int Zoltan_HSFC_compare (const void *key, const void *arg)
{
if ( *(double*) key >= ((Partition*) arg)->r) return 1;
if ( *(double*) key < ((Partition*) arg)->l) return -1;
if ( *(const double*) key >= ((const Partition*) arg)->r) return 1;
if ( *(const double*) key < ((const Partition*) arg)->l) return -1;

return 0; /* key in arg interval [l,r) */
}
Expand Down
6 changes: 6 additions & 0 deletions packages/zoltan/src/lb/lb_balance.c
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,12 @@ static int search_hash_table(ZZ *, ZOLTAN_ID_PTR gid,
struct Hash_Node **ht, int tableSize);
static void free_hash_table(struct Hash_Node **ht, int tableSize);

static void Zoltan_PartDist_MPIOp(
void *in,
void *inout,
int *len,
MPI_Datatype *dptr);


/****************************************************************************/
/****************************************************************************/
Expand Down
1 change: 1 addition & 0 deletions packages/zoltan/src/order/hsfcOrder.c
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ extern "C" {
#include "zz_const.h"
#include "zz_sort.h"
#include "hsfc_hilbert_const.h"
#include "hsfcOrder.h"


int Zoltan_LocalHSFC_Order(
Expand Down
3 changes: 1 addition & 2 deletions packages/zoltan/src/par/par_average.c
Original file line number Diff line number Diff line change
Expand Up @@ -53,11 +53,10 @@ extern "C" {
#include <stdio.h>
#include <stdlib.h>
#include <float.h>
#include "par_average_const.h"
#include "par_median_const.h"
#include "zz_const.h"

#define TINY 1.0e-6

/* prototypes for TFLOPS_SPECIAL */
static void Zoltan_average_cuts_reduce(int, int, int, double *, double *,
int, MPI_Datatype, MPI_Comm);
Expand Down
4 changes: 3 additions & 1 deletion packages/zoltan/src/par/par_bisect.c
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,8 @@ static double eval_cut_quality(int, double *, double *, double *, double *,
int);
static void compute_weight_sums( int, int *, int, double *, double,
double *, double *, MPI_Comm, int, int, int, int);
static void Zoltan_bisector_merge(void *in, void *inout, int *len, MPI_Datatype *dptr);

#endif /* RB_MAX_WGTS > 1 */

/*****************************************************************************/
Expand Down Expand Up @@ -1251,7 +1253,7 @@ static double eval_cut_quality(
*/
void Zoltan_bisector_merge(void *in, void *inout, int *len, MPI_Datatype *dptr)
static void Zoltan_bisector_merge(void *in, void *inout, int *len, MPI_Datatype *dptr)
{
struct bisector *med1, *med2;
int i, nwgts;
Expand Down
6 changes: 3 additions & 3 deletions packages/zoltan/src/par/par_median_randomized.c
Original file line number Diff line number Diff line change
Expand Up @@ -77,12 +77,12 @@ typedef struct _commStruct{
MPI_Comm comm;
}commStruct;

int rb_sort_doubles_increasing(const void *a, const void *b)
static int rb_sort_doubles_increasing(const void *a, const void *b)
{
double v1, v2;

v1 = *(double *)a;
v2 = *(double *)b;
v1 = *(const double *)a;
v2 = *(const double *)b;

if (v1 < v2) return -1;
else if (v1 > v2) return 1;
Expand Down
2 changes: 1 addition & 1 deletion packages/zoltan/src/phg/phg_serialpartition.c
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ const int num_coarse_iter = 1 + 9/zz->Num_Proc;

/* Force LocalCoarsePartition if large global graph */
#define LARGE_GRAPH_VTX 64000
#define LARGE_GRAPH_PINS 256000
/*#define LARGE_GRAPH_PINS 256000*/
if (phg->dist_x[phg->comm->nProc_x] > LARGE_GRAPH_VTX){
/* TODO: || (global_nPins > LARGE_GRAPH_PINS) */
local_coarse_part = 1;
Expand Down
2 changes: 1 addition & 1 deletion packages/zoltan/src/rcb/rcb_util.c
Original file line number Diff line number Diff line change
Expand Up @@ -227,7 +227,7 @@ void Zoltan_RCB_Serialize_Structure(ZZ const *zz, char **buf)
memcpy(bufptr, (void *)(zzrcb->Box), sizeof(struct rcb_box));
bufptr += sizeof(struct rcb_box);

memcpy(bufptr, (void *) &(zzrcb->Tran), sizeof(ZZ_Transform));
memcpy(bufptr, (const void *) &(zzrcb->Tran), sizeof(ZZ_Transform));
bufptr += sizeof(ZZ_Transform);

*buf = bufptr;
Expand Down
2 changes: 1 addition & 1 deletion packages/zoltan/src/reftree/reftree_coarse_path.c
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ static int *to_add_ptr;

/* in this file the vertices are integers from 0 to nvert-1, but in the
input/output arguments they are gids. vertex_gid maps from int to gid */
ZOLTAN_ID_PTR vertex_gid;
static ZOLTAN_ID_PTR vertex_gid;

/* variables for each element which define the path */
static int *prev, *next, *in, *out, *onpath;
Expand Down
4 changes: 3 additions & 1 deletion packages/zoltan/src/tpls/postprocessing.c
Original file line number Diff line number Diff line change
Expand Up @@ -223,7 +223,8 @@ Zoltan_Postprocess_Order (ZZ *zz,

/* Fill in the Zoltan Order Struct */
/* EBEB: For now, discard separator info */
if (0){ /* DEBUG: Print separator sizes to file */
#if 0
{ /* DEBUG: Print separator sizes to file */
FILE *fp;
fp = fopen("separators.txt", "w");
fprintf(fp, "%i\n", ord->num_part);
Expand All @@ -237,6 +238,7 @@ Zoltan_Postprocess_Order (ZZ *zz,
fprintf(fp, "\n");
fclose(fp);
}
#endif

return (ierr);
}
Expand Down
4 changes: 2 additions & 2 deletions packages/zoltan/src/tpls/verify_graph.c
Original file line number Diff line number Diff line change
Expand Up @@ -562,8 +562,8 @@ int Zoltan_Verify_Graph(MPI_Comm comm, indextype *vtxdist, indextype *xadj,
/* comparison routine for bsearch */
static int Zoltan_Compare_Indextypes(const void *key, const void *arg)
{
if ( *(indextype*) key > (*(indextype*) arg)) return 1;
if ( *(indextype*) key < (*(indextype*) arg)) return -1;
if ( *(const indextype*) key > (*(const indextype*) arg)) return 1;
if ( *(const indextype*) key < (*(const indextype*) arg)) return -1;

return 0; /* equal */
}
Expand Down
1 change: 0 additions & 1 deletion packages/zoltan/src/zz/zz_coord.c
Original file line number Diff line number Diff line change
Expand Up @@ -816,7 +816,6 @@ static void order_decreasing(double *d, int *order)
* Assume dim is 2 or 3.
*/

#define SIGN(a,b) ((b) < 0 ? -fabs(a) : fabs(a))
static int eigenvectors(double (*m)[3], double (*evecs)[3], int dim)
{
double temp[2][2];
Expand Down
8 changes: 6 additions & 2 deletions packages/zoltan/src/zz/zz_set_fn.c
Original file line number Diff line number Diff line change
Expand Up @@ -271,9 +271,11 @@ int ierr;
ierr = Zoltan_Set_Hier_Method_Fn(zz,
(ZOLTAN_HIER_METHOD_FN *) fn, data);
break;
case ZOLTAN_PROC_NAME_FN_TYPE:
case ZOLTAN_MAX_FN_TYPES:
default:
sprintf(msg, "ZOLTAN_FN_TYPE %d is invalid.\n"
"Value must be in range 0 to %d.", fn_type, ZOLTAN_MAX_FN_TYPES);
"Value must be in range 0 to %d.", fn_type, ZOLTAN_MAX_FN_TYPES - 1);
ZOLTAN_PRINT_ERROR(zz->Proc, yo, msg);
ierr = ZOLTAN_WARN;
}
Expand Down Expand Up @@ -484,9 +486,11 @@ int ierr = ZOLTAN_OK;
*fn = (ZOLTAN_VOID_FN *) zz->Get_Hier_Method;
*data = zz->Get_Hier_Method_Data;
break;
case ZOLTAN_PROC_NAME_FN_TYPE:
case ZOLTAN_MAX_FN_TYPES:
default:
sprintf(msg, "ZOLTAN_FN_TYPE %d is invalid.\n"
"Value must be in range 0 to %d.", fn_type, ZOLTAN_MAX_FN_TYPES);
"Value must be in range 0 to %d.", fn_type, ZOLTAN_MAX_FN_TYPES - 1);
*fn = NULL;
*data = NULL;
ZOLTAN_PRINT_ERROR(zz->Proc, yo, msg);
Expand Down
2 changes: 1 addition & 1 deletion packages/zoltan/src/zz/zz_struct.c
Original file line number Diff line number Diff line change
Expand Up @@ -403,7 +403,7 @@ int Zoltan_Serialize(ZZ const *zz, size_t bufSize, char *buf)
*intptr = zz->Debug_Proc; intptr++;
*intptr = zz->Fortran; intptr++;
*intptr = zz->Tflops_Special; intptr++;
*intptr = *((int*) &(zz->Seed)); intptr++;
*intptr = *((const int*) &(zz->Seed)); intptr++;
*intptr = zz->Deterministic; intptr++;
*intptr = zz->Obj_Weight_Dim; intptr++;
*intptr = zz->Edge_Weight_Dim; intptr++;
Expand Down
8 changes: 8 additions & 0 deletions signatures/version1/cla.json
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,14 @@
"created_at": "2023-03-31T15:59:13Z",
"repoId": 36943822,
"pullRequestNo": 374
},
{
"name": "seanm",
"id": 117260,
"comment_id": 1806968902,
"created_at": "2023-11-12T01:33:41Z",
"repoId": 36943822,
"pullRequestNo": 421
}
]
}

0 comments on commit 169e361

Please sign in to comment.