Commit 6db5ecea authored by Matthieu Schaller's avatar Matthieu Schaller
Browse files

Merge branch 'spellings' into 'master'

Fix up many and varied spelling issues, the main one being "Coypright".

Ran the comments and strings through a spelling check and came up with
all these.

See merge request !54
parents 69638826 94675457
/*******************************************************************************
* This file is part of SWIFT.
* Coypright (c) 2012 Pedro Gonnet (pedro.gonnet@durham.ac.uk)
* Copyright (c) 2012 Pedro Gonnet (pedro.gonnet@durham.ac.uk)
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published
......
/*******************************************************************************
* This file is part of SWIFT.
* Coypright (c) 2012 Pedro Gonnet (pedro.gonnet@durham.ac.uk),
* Copyright (c) 2012 Pedro Gonnet (pedro.gonnet@durham.ac.uk),
* Matthieu Schaller (matthieu.schaller@durham.ac.uk).
*
* This program is free software: you can redistribute it and/or modify
......@@ -218,7 +218,7 @@ void writeStringAttribute(hid_t grp, char* name, const char* str, int length) {
/**
* @brief Writes a double value as an attribute
* @param grp The groupm in which to write
* @param grp The group in which to write
* @param name The name of the attribute
* @param data The value to write
*/
......@@ -228,7 +228,7 @@ void writeAttribute_d(hid_t grp, char* name, double data) {
/**
* @brief Writes a float value as an attribute
* @param grp The groupm in which to write
* @param grp The group in which to write
* @param name The name of the attribute
* @param data The value to write
*/
......@@ -238,7 +238,7 @@ void writeAttribute_f(hid_t grp, char* name, float data) {
/**
* @brief Writes an int value as an attribute
* @param grp The groupm in which to write
* @param grp The group in which to write
* @param name The name of the attribute
* @param data The value to write
*/
......@@ -249,7 +249,7 @@ void writeAttribute_i(hid_t grp, char* name, int data) {
/**
* @brief Writes a long value as an attribute
* @param grp The groupm in which to write
* @param grp The group in which to write
* @param name The name of the attribute
* @param data The value to write
*/
......@@ -259,7 +259,7 @@ void writeAttribute_l(hid_t grp, char* name, long data) {
/**
* @brief Writes a string value as an attribute
* @param grp The groupm in which to write
* @param grp The group in which to write
* @param name The name of the attribute
* @param str The string to write
*/
......
/*******************************************************************************
* This file is part of SWIFT.
* Coypright (c) 2012 Pedro Gonnet (pedro.gonnet@durham.ac.uk),
* Copyright (c) 2012 Pedro Gonnet (pedro.gonnet@durham.ac.uk),
* Matthieu Schaller (matthieu.schaller@durham.ac.uk).
*
* This program is free software: you can redistribute it and/or modify
......
/*******************************************************************************
* This file is part of SWIFT.
* Coypright (c) 2012 Pedro Gonnet (ptcedro.gonnet@durham.ac.uk)
* Copyright (c) 2012 Pedro Gonnet (ptcedro.gonnet@durham.ac.uk)
* Matthieu Schaller (matthieu.schaller@durham.ac.uk)
*
* This program is free software: you can redistribute it and/or modify
......
/*******************************************************************************
* This file is part of SWIFT.
* Coypright (c) 2013 Matthieu Schaller (matthieu.schaller@durham.ac.uk),
* Copyright (c) 2013 Matthieu Schaller (matthieu.schaller@durham.ac.uk),
* Pedro Gonnet (pedro.gonnet@durham.ac.uk).
*
* This program is free software: you can redistribute it and/or modify
......
/*******************************************************************************
* This file is part of SWIFT.
* Coypright (c) 2012 Matthieu Schaller (matthieu.schaller@durham.ac.uk).
* Copyright (c) 2012 Matthieu Schaller (matthieu.schaller@durham.ac.uk).
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published
......
/*******************************************************************************
* This file is part of SWIFT.
* Coypright (c) 2012 Pedro Gonnet (pedro.gonnet@durham.ac.uk)
* Copyright (c) 2012 Pedro Gonnet (pedro.gonnet@durham.ac.uk)
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published
......@@ -127,7 +127,7 @@ void engine_mkghosts(struct engine *e, struct cell *c, struct cell *super) {
}
/**
* @brief Redistribute the particles amongst the nodes accorind
* @brief Redistribute the particles amongst the nodes according
* to their cell's node IDs.
*
* @param e The #engine.
......@@ -454,7 +454,7 @@ void engine_repartition(struct engine *e) {
for (k = 0; k < nr_cells; k++) weights_v[k] *= scale;
}
/* Merge the weights arrays accross all nodes. */
/* Merge the weights arrays across all nodes. */
#if IDXTYPEWIDTH == 32
if ((res = MPI_Reduce((nodeID == 0) ? MPI_IN_PLACE : weights_v, weights_v,
nr_cells, MPI_INT, MPI_SUM, 0, MPI_COMM_WORLD)) !=
......@@ -577,7 +577,7 @@ void engine_repartition(struct engine *e) {
/* Now comes the tricky part: Exchange particles between all nodes.
This is done in two steps, first allreducing a matrix of
how many particles go from where to where, then re-allocating
the parts array, and emiting the sends and receives.
the parts array, and emitting the sends and receives.
Finally, the space, tasks, and proxies need to be rebuilt. */
/* Redistribute the particles between the nodes. */
......@@ -765,7 +765,7 @@ void engine_exchange_cells(struct engine *e) {
proxy_cells_exch2(&e->proxies[pid]);
}
/* Wait for all the sends to have finnished too. */
/* Wait for all the sends to have finished too. */
if (MPI_Waitall(nr_proxies, reqs_out, MPI_STATUSES_IGNORE) != MPI_SUCCESS)
error("MPI_Waitall on sends failed.");
......@@ -786,7 +786,7 @@ void engine_exchange_cells(struct engine *e) {
e->proxies[pid].cells_in[j], e->s);
}
/* Wait for all the sends to have finnished too. */
/* Wait for all the sends to have finished too. */
if (MPI_Waitall(nr_proxies, reqs_out, MPI_STATUSES_IGNORE) != MPI_SUCCESS)
error("MPI_Waitall on sends failed.");
......@@ -883,11 +883,11 @@ int engine_exchange_strays(struct engine *e, int offset, int *ind, int N) {
proxy_parts_exch2(&e->proxies[pid]);
}
/* Wait for all the sends to have finnished too. */
/* Wait for all the sends to have finished too. */
if (MPI_Waitall(e->nr_proxies, reqs_out, MPI_STATUSES_IGNORE) != MPI_SUCCESS)
error("MPI_Waitall on sends failed.");
/* Count the total number of incomming particles and make sure we have
/* Count the total number of incoming particles and make sure we have
enough space to accommodate them. */
int count_in = 0;
for (k = 0; k < e->nr_proxies; k++) count_in += e->proxies[k].nr_parts_in;
......@@ -954,7 +954,7 @@ int engine_exchange_strays(struct engine *e, int offset, int *ind, int N) {
}
}
/* Wait for all the sends to have finnished too. */
/* Wait for all the sends to have finished too. */
if (nr_out > 0)
if (MPI_Waitall(2 * e->nr_proxies, reqs_out, MPI_STATUSES_IGNORE) !=
MPI_SUCCESS)
......@@ -1207,7 +1207,7 @@ void engine_maketasks(struct engine *e) {
/* Get a handle on the proxy. */
struct proxy *p = &e->proxies[pid];
/* Loop through the proxy's incomming cells and add the
/* Loop through the proxy's incoming cells and add the
recv tasks. */
for (k = 0; k < p->nr_cells_in; k++)
engine_addtasks_recv(e, p->cells_in[k], NULL, NULL);
......@@ -1245,7 +1245,7 @@ int engine_marktasks(struct engine *e) {
struct cell *ci, *cj;
// ticks tic = getticks();
/* Muc less to do here if we're on a fixed time-step. */
/* Much less to do here if we're on a fixed time-step. */
if (!(e->policy & engine_policy_multistep)) {
/* Run through the tasks and mark as skip or not. */
......@@ -1440,7 +1440,7 @@ void engine_prepare(struct engine *e) {
int buff;
if (MPI_Allreduce(&rebuild, &buff, 1, MPI_INT, MPI_MAX, MPI_COMM_WORLD) !=
MPI_SUCCESS)
error("Failed to aggreggate the rebuild flag accross nodes.");
error("Failed to aggregate the rebuild flag across nodes.");
rebuild = buff;
// message( "rebuild allreduce took %.3f ms." , (double)(getticks() -
// tic)/CPU_TPS*1000 );
......@@ -1491,7 +1491,7 @@ void engine_barrier(struct engine *e, int tid) {
/* Wait for the barrier to open. */
while (e->barrier_launch == 0 || tid >= e->barrier_launchcount)
if (pthread_cond_wait(&e->barrier_cond, &e->barrier_mutex) != 0)
error("Eror waiting for barrier to close.");
error("Error waiting for barrier to close.");
/* This thread has been launched. */
e->barrier_running += 1;
......@@ -1708,7 +1708,7 @@ void engine_launch(struct engine *e, int nr_runners, unsigned int mask) {
void hassorted(struct cell *c) {
if (c->sorted) error("Suprious sorted flags.");
if (c->sorted) error("Spurious sorted flags.");
if (c->split)
for (int k = 0; k < 8; k++)
......@@ -2071,7 +2071,7 @@ void engine_split(struct engine *e, int *grid) {
* @param nr_queues The number of task queues to create.
* @param nr_nodes The number of MPI ranks
* @param nodeID The MPI rank of this node
* @param policy The queueing policy to use.
* @param policy The queuing policy to use.
*/
void engine_init(struct engine *e, struct space *s, float dt, int nr_threads,
......
/*******************************************************************************
* This file is part of SWIFT.
* Coypright (c) 2012 Pedro Gonnet (pedro.gonnet@durham.ac.uk)
* Copyright (c) 2012 Pedro Gonnet (pedro.gonnet@durham.ac.uk)
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published
......
/*******************************************************************************
* This file is part of SWIFT.
* Coypright (c) 2012 Pedro Gonnet (pedro.gonnet@durham.ac.uk),
* Copyright (c) 2012 Pedro Gonnet (pedro.gonnet@durham.ac.uk),
* Matthieu Schaller (matthieu.schaller@durham.ac.uk).
*
* This program is free software: you can redistribute it and/or modify
......
/*******************************************************************************
* This file is part of SWIFT.
* Coypright (c) 2012 Pedro Gonnet (pedro.gonnet@durham.ac.uk),
* Copyright (c) 2012 Pedro Gonnet (pedro.gonnet@durham.ac.uk),
* Matthieu Schaller (matthieu.schaller@durham.ac.uk).
*
* This program is free software: you can redistribute it and/or modify
......
/*******************************************************************************
* This file is part of SWIFT.
* Coypright (c) 2015 Matthieu Schaller matthieu.schaller@durham.ac.uk)
* Copyright (c) 2015 Matthieu Schaller matthieu.schaller@durham.ac.uk)
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published
......@@ -24,7 +24,7 @@
* significant bit position. If x is 0, the result is undefined.
*
* This is a wrapper for the GCC intrinsics with an implementation (from
* Hacker's Delight) if the compiler intrisincs are not available.
* Hacker's Delight) if the compiler intrinsics are not available.
*/
__attribute__((always_inline))
INLINE static int intrinsics_clz(unsigned int x) {
......@@ -64,7 +64,7 @@ __attribute__((always_inline))
* @brief Returns the number of 1-bits in x.
*
* This is a wrapper for the GCC intrinsics with an implementation (from
* Hacker's Delight) if the compiler intrisincs are not available.
* Hacker's Delight) if the compiler intrinsics are not available.
*/
__attribute__((always_inline))
INLINE static int intrinsics_popcount(unsigned int x) {
......
/*******************************************************************************
* This file is part of SWIFT.
* Coypright (c) 2012 Pedro Gonnet (pedro.gonnet@durham.ac.uk)
* Copyright (c) 2012 Pedro Gonnet (pedro.gonnet@durham.ac.uk)
* Matthieu Schaller (matthieu.schaller@durham.ac.uk)
*
* This program is free software: you can redistribute it and/or modify
......
/*******************************************************************************
* This file is part of SWIFT.
* Coypright (c) 2012 Pedro Gonnet (pedro.gonnet@durham.ac.uk)
* Copyright (c) 2012 Pedro Gonnet (pedro.gonnet@durham.ac.uk)
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published
......
/*******************************************************************************
* This file is part of SWIFT.
* Coypright (c) 2013 Pedro Gonnet (pedro.gonnet@durham.ac.uk)
* Copyright (c) 2013 Pedro Gonnet (pedro.gonnet@durham.ac.uk)
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published
......
/*******************************************************************************
* This file is part of SWIFT.
* Coypright (c) 2013 Pedro Gonnet (pedro.gonnet@durham.ac.uk)
* Copyright (c) 2013 Pedro Gonnet (pedro.gonnet@durham.ac.uk)
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published
......
/*******************************************************************************
* This file is part of SWIFT.
* Coypright (c) 2012 Pedro Gonnet (pedro.gonnet@durham.ac.uk),
* Copyright (c) 2012 Pedro Gonnet (pedro.gonnet@durham.ac.uk),
* Matthieu Schaller (matthieu.schaller@durham.ac.uk).
*
* This program is free software: you can redistribute it and/or modify
......@@ -47,14 +47,14 @@
* @param type The #DATA_TYPE of the attribute.
* @param N The number of particles.
* @param dim The dimension of the data (1 for scalar, 3 for vector)
* @param part_c A (char*) pointer on the first occurence of the field of
* @param part_c A (char*) pointer on the first occurrence of the field of
*interest in the parts array
* @param importance If COMPULSORY, the data must be present in the IC file. If
*OPTIONAL, the array will be zeroed when the data is not present.
*
* @todo A better version using HDF5 hyperslabs to read the file directly into
* @todo A better version using HDF5 hyper-slabs to read the file directly into
*the part array
* will be written once the strucutres have been stabilized.
* will be written once the structures have been stabilized.
*
* Calls #error() if an error occurs.
*/
......@@ -102,7 +102,7 @@ void readArrayBackEnd(hid_t grp, char* name, enum DATA_TYPE type, int N,
temp = malloc(N * dim * typeSize);
if (temp == NULL) error("Unable to allocate memory for temporary buffer");
/* Prepare information for hyperslab */
/* Prepare information for hyper-slab */
if (dim > 1) {
rank = 2;
shape[0] = N;
......@@ -120,7 +120,7 @@ void readArrayBackEnd(hid_t grp, char* name, enum DATA_TYPE type, int N,
/* Create data space in memory */
h_memspace = H5Screate_simple(rank, shape, NULL);
/* Select hyperslab in file */
/* Select hyper-slab in file */
h_filespace = H5Dget_space(h_data);
H5Sselect_hyperslab(h_filespace, H5S_SELECT_SET, offsets, NULL, shape, NULL);
......@@ -185,7 +185,7 @@ void readArrayBackEnd(hid_t grp, char* name, enum DATA_TYPE type, int N,
* in the file.
*
* @warning Can not read snapshot distributed over more than 1 file !!!
* @todo Read snaphsots distributed in more than one file.
* @todo Read snapshots distributed in more than one file.
*
* Calls #error() if an error occurs.
*
......@@ -309,14 +309,14 @@ void read_ic_parallel(char* fileName, double dim[3], struct part** parts,
* @param dim The dimension of the data (1 for scalar, 3 for vector)
* @param N_total Total number of particles across all cores
* @param offset Offset in the array where this mpi task starts writing
* @param part_c A (char*) pointer on the first occurence of the field of
* @param part_c A (char*) pointer on the first occurrence of the field of
*interest in the parts array
* @param us The UnitSystem currently in use
* @param convFactor The UnitConversionFactor for this array
*
* @todo A better version using HDF5 hyperslabs to write the file directly from
* @todo A better version using HDF5 hyper-slabs to write the file directly from
*the part array
* will be written once the strucutres have been stabilized.
* will be written once the structures have been stabilized.
*
* Calls #error() if an error occurs.
*/
......@@ -416,8 +416,8 @@ void writeArrayBackEnd(hid_t grp, char* fileName, FILE* xmfFile, char* name,
conversionString(buffer, us, convFactor);
writeAttribute_d(h_data, "CGS conversion factor",
conversionFactor(us, convFactor));
writeAttribute_f(h_data, "h-scale exponant", hFactor(us, convFactor));
writeAttribute_f(h_data, "a-scale exponant", aFactor(us, convFactor));
writeAttribute_f(h_data, "h-scale exponent", hFactor(us, convFactor));
writeAttribute_f(h_data, "a-scale exponent", aFactor(us, convFactor));
writeAttribute_s(h_data, "Conversion factor", buffer);
/* Free and close everything */
......@@ -441,7 +441,7 @@ void writeArrayBackEnd(hid_t grp, char* fileName, FILE* xmfFile, char* name,
* @param N_total Total number of particles across all cores
* @param mpi_rank The MPI task rank calling the function
* @param offset Offset in the array where this mpi task starts writing
* @param part A (char*) pointer on the first occurence of the field of interest
* @param part A (char*) pointer on the first occurrence of the field of interest
*in the parts array
* @param field The name (code name) of the field to read from.
* @param us The UnitSystem currently in use
......@@ -511,7 +511,7 @@ void write_output_parallel(struct engine* e, struct UnitSystem* us,
MPI_Bcast(&N_total_d, 1, MPI_DOUBLE, mpi_size - 1, comm);
if (N_total_d > 1.e15)
error(
"Error while computing the offest for parallel output: Simulation has "
"Error while computing the offset for parallel output: Simulation has "
"more than 10^15 particles.\n");
N_total = (long long)N_total_d;
offset = (long long)offset_d;
......
/*******************************************************************************
* This file is part of SWIFT.
* Coypright (c) 2012 Matthieu Schaller (matthieu.schaller@durham.ac.uk).
* Copyright (c) 2012 Matthieu Schaller (matthieu.schaller@durham.ac.uk).
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published
......
/*******************************************************************************
* This file is part of SWIFT.
* Coypright (c) 2012 Pedro Gonnet (pedro.gonnet@durham.ac.uk)
* Copyright (c) 2012 Pedro Gonnet (pedro.gonnet@durham.ac.uk)
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published
......
/*******************************************************************************
* This file is part of SWIFT.
* Coypright (c) 2013 Pedro Gonnet (pedro.gonnet@durham.ac.uk)
* Copyright (c) 2013 Pedro Gonnet (pedro.gonnet@durham.ac.uk)
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published
......@@ -142,7 +142,7 @@ void proxy_addcell_in(struct proxy *p, struct cell *c) {
if (p->nr_cells_in == p->size_cells_in) {
p->size_cells_in *= proxy_buffgrow;
if ((temp = malloc(sizeof(struct cell *) * p->size_cells_in)) == NULL)
error("Failed to allocate ingoing cell list.");
error("Failed to allocate incoming cell list.");
memcpy(temp, p->cells_in, sizeof(struct cell *) * p->nr_cells_in);
free(p->cells_in);
p->cells_in = temp;
......
/*******************************************************************************
* This file is part of SWIFT.
* Coypright (c) 2013 Pedro Gonnet (pedro.gonnet@durham.ac.uk)
* Copyright (c) 2013 Pedro Gonnet (pedro.gonnet@durham.ac.uk)
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published
......@@ -40,7 +40,7 @@ struct proxy {
/* ID of the node this proxy represents. */
int mynodeID, nodeID;
/* Incomming cells. */
/* Incoming cells. */
struct cell **cells_in;
struct pcell *pcells_in;
int nr_cells_in, size_cells_in, size_pcells_in;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment