NAMD
Public Member Functions | List of all members
main Class Reference
Inheritance diagram for main:

Public Member Functions

 main (CkArgMsg *msg)
 

Detailed Description

Definition at line 126 of file main.C.

Constructor & Destructor Documentation

◆ main()

main::main ( CkArgMsg *  msg)
inline

Definition at line 129 of file main.C.

References endi(), iINFO(), iout, iWARN(), memusage(), memusage_MB(), namd_build_date, namd_build_machine, namd_build_user, namd_commit_id, NAMD_die(), RegisterNamdEventsProfiling(), and tbsoft_sendusage().

130  {
131 
132  // print banner
133  iout << iINFO << "NAMD " << NAMD_VERSION << " for " << NAMD_PLATFORM
134  << "\n"
135 #ifdef MEM_OPT_VERSION
136  << iWARN << "\n"
137  << iWARN << " *** EXPERIMENTAL MEMORY OPTIMIZED VERSION ***\n"
138  << iWARN << "\n"
139 #endif
140 #if 0
141  << iWARN << "\n"
142  << iWARN << " *** UNRELEASED EXPERIMENTAL VERSION ***\n"
143  << iWARN << "\n"
144 #endif
145 #ifdef SPEC_DISABLED_VERSION
146 
147  << iINFO << "\n"
148  << iINFO << "NAMD is a parallel, object-oriented molecular dynamics\n"
149  << iINFO << "code designed for high-performance simulation of large\n"
150  << iINFO << "biomolecular systems. NAMD is distributed free of\n"
151  << iINFO << "charge and includes source code. For more information\n"
152  << iINFO << "please visit http://www.ks.uiuc.edu/Research/namd/\n"
153  << iINFO << "\n"
154  << iINFO << "*********************************************************\n"
155  << iINFO << "This version of NAMD may be distributed only as a part of\n"
156  << iINFO << "the SPEC Workstation Benchmark and all other distribution\n"
157  << iINFO << "is prohibited. Any use of this software is bound by\n"
158  << iINFO << "the terms of the NAMD License, which is available at\n"
159  << iINFO << "http://www.ks.uiuc.edu/Research/namd/license.html\n"
160  << iINFO << "The NAMD development team will not provide support for\n"
161  << iINFO << "any version of NAMD unless you have first registered\n"
162  << iINFO << "and downloaded the latest version of NAMD available at\n"
163  << iINFO << "http://www.ks.uiuc.edu/Research/namd/\n"
164  << iINFO << "*********************************************************\n"
165 #else
166  << iINFO << "\n"
167  << iINFO << "Please visit http://www.ks.uiuc.edu/Research/namd/\n"
168  << iINFO << "for updates, documentation, and support information.\n"
169 #endif
170 << iINFO << "\n"
171 << iINFO << "Please cite Phillips et al., J. Chem. Phys. 153:044130 (2020) "
172  "doi:10.1063/5.0014475\n"
173 << iINFO << "in all publications reporting results obtained with NAMD.\n"
174 << iINFO << "\n"
175  << endi;
176 
177  char charm_version[64];
178  sprintf(charm_version,"%d",CHARM_VERSION);
179 
180 #if CHARM_VERSION < 60500
181 #error "Charm++ 6.5.1 or later is required to build NAMD"
182 #endif
183 
184  iout << iINFO << "Based on Charm++/Converse " << charm_version
185  << " for " << CMK_MACHINE_NAME << "\n" << endi;
186 
187  iout << iINFO << "Built " << namd_build_date << " by "
188  << namd_build_user << " on " << namd_build_machine << "\n"
189  << endi;
190 
191  if (strlen(namd_commit_id) > 0) {
192  iout << iINFO << "Source code at Git commit ID "
193  << namd_commit_id << "\n"
194  << endi;
195  }
196 
197 #ifndef NO_SOCKET
198  char numcpus[512];
199  sprintf(numcpus,"%d",CkNumPes());
200  tbsoft_sendusage("NAMD",NAMD_VERSION,NAMD_PLATFORM,numcpus,"");
201 #endif
202 
203 #if CMK_BLUEGENE_CHARM
204  iout << iINFO << "Running on BigSim using " << CmiNumPes() << " real processors.\n" << endi;
205 #endif
206  iout << iINFO << "Running on " << CkNumPes() << " processors, "
207  << CmiNumNodes() << " nodes, "
208  << CmiNumPhysicalNodes() << " physical nodes.\n" << endi;
209  iout << iINFO << "CPU topology information " << (CmiCpuTopologyEnabled()?"available":"unavailable") << ".\n" << endi;
210  iout << iINFO << "Charm++/Converse parallel runtime startup completed at "
211  << CmiWallTimer() << " s\n"<< endi;
212  const char* memsource;
213  memusage(&memsource);
214  iout << iINFO << memusage_MB() << " MB of memory in use"
215  << " based on " << memsource << "\n";
216 
217 #if 0
218  if ( CmiNumNodes() > 1 && CkNumPes() == CmiNumNodes() ) {
219  NAMD_die("SMP build launched as multiple single-thread processes. Use ++ppn to set number of worker threads per process to match available cores, reserving one core per process for communication thread.");
220  }
221 #endif
222  // Register events marked for profiling
224 
225  // diagnostic information
226 #if 0
227 #ifndef USE_NO_BITFIELDS
228  iout << iINFO << "Using bitfields in atom data structures.\n" << endi;
229 #else
230  iout << iINFO << "Using NO bitfields in atom data structures.\n" << endi;
231 #endif
232  iout << iINFO << " sizeof( CompAtom ) = " << int(sizeof(CompAtom))
233  << "\n"
234  << iINFO << " sizeof( CompAtomExt ) = " << int(sizeof(CompAtomExt))
235  << "\n"
236  << endi;
237 #endif
238  }
const char * namd_commit_id
std::ostream & iINFO(std::ostream &s)
Definition: InfoStream.C:81
const char * namd_build_date
int tbsoft_sendusage(const char *program, const char *versionnum, const char *platform, const char *numcpus, const char *miscinfo)
Definition: main.C:80
std::ostream & endi(std::ostream &s)
Definition: InfoStream.C:54
const char * namd_build_machine
std::ostream & iWARN(std::ostream &s)
Definition: InfoStream.C:82
#define iout
Definition: InfoStream.h:51
double memusage_MB()
Definition: memusage.h:13
const char * namd_build_user
void NAMD_die(const char *err_msg)
Definition: common.C:147
void RegisterNamdEventsProfiling()
Definition: main.C:47
unsigned long memusage(const char **source)
Definition: memusage.C:158

The documentation for this class was generated from the following file: