Commit Graph

836 Commits

Author SHA1 Message Date
Alex Lin
008337e69b Monte Carlo dry runs produce monte_input files #318
The input file that is created while running monte carlo runs is done
in 3 different places.  There was no easy way to collect all of those
lines in one place, so I duplicated the lines in the dryrun function.
2017-01-12 16:52:05 -06:00
Derek Bankieris
a8c41d7cb5 Move new Python modules to intended location
They're supposed to be at the top level, not in share. Oops!

Refs #365
2017-01-12 14:52:43 -06:00
Derek Bankieris
93f1828fb9 Introduce Python variable server client module
I also made a wiki page: Python Variable Server Client

Refs #365
2017-01-12 14:43:31 -06:00
Alex Lin
c796522d92 Check link dependencies against exclude flags #351
Added the directories in TRICK_EXT_LIB_DIRS to the directories in
TRICK_EXCLUDE to exclude all source files that are to be built
in libraries.
2017-01-12 14:33:39 -06:00
Alex Lin
2c93f2ac75 Improve error handling when duplicate variable added to a DRHDF5 #353
Added a printout that shows the logging group and variable name that
had a problem when trying to add to the HDF5 recording.
2017-01-12 08:44:30 -06:00
Alex Lin
8a0653fa09 Detect when TRICK_ICG is used in header files and compensate for it. #375
clang call to addPPCallbacks changed between clang versions 3.5 and 3.6.
2017-01-12 08:42:16 -06:00
Alex Lin
4b28951c1c When doing input file verification the exit code is always 1. #335
After doing verification of the input file we return the exit code
of the python processor.
2017-01-11 17:40:05 -06:00
Alex Lin
9f01209316 ICG generates non-compilable io_* code for std::vector::iterator members #331
Added a test if our field is an iterator type.  If it is we cannot create io_src
code for it.  We skip it once identified.
2017-01-11 16:07:02 -06:00
Alex Lin
b60320464a Detect when TRICK_ICG is used in header files and compensate for it. #375
Always differences between clang versions.
2017-01-11 15:59:10 -06:00
Alex Lin
ba47c2048c Detect when TRICK_ICG is used in header files and compensate for it. #375
Created a hook for the clang preprocessor.  The hook does 2 things.  It
keeps track to which header files we have entered and exited.  Second it
searches for the use of TRICK_ICG.  If we find an instance of TRICK_ICG we
mark all of the included files from this point up the chain as requiring
compensation.  To compensate for using TRICK_ICG we write out the older
offset statements to get the location of variables in classes/structures.
2017-01-11 15:02:21 -06:00
Alex Lin
0140b0b966 Add ability to use doxygen style library dependencies in S_define file. #373
Added a regular expression to collect the library dependencies in the S_define
file.
2017-01-10 08:09:19 -06:00
Alex Lin
0197df7103 Test output xml does not validate. #372
Removed the parent attribute.
2017-01-09 09:52:48 -06:00
Derek Bankieris
c3b5da975a Oops
Refs #369
2017-01-09 08:40:27 -06:00
Alex Lin
a831cbfaa8 Merge pull request #366 from iamthad/use_stderr
Use std::cerr instead of std::cout for error messages
2016-12-20 15:02:23 -06:00
Derek Bankieris
7a08829d3d Introduce makefile variable TRICK_SYSTEM_LDFLAGS
Like other TRICK_SYSTEM variables, users should not modify this.

This renders TRICK_LDFLAGS and TRICK_USER_LINK_LIBS redundant. While we
would like to eventually remove TRICK_USER_LINK_LIBS, it's not likely to
ever actually happen.

Refs #369
2016-12-14 12:36:21 -06:00
Derek Bankieris
76f6a003b3 Add -std=c++11 to VariableServer Makefile
Refs #367
2016-12-14 10:06:01 -06:00
Derek Bankieris
634d561567 Fix VariableServerThread::var_units
Refs #367
2016-12-14 09:43:55 -06:00
Derek Bankieris
2c9181a896 Infer TRICK_HOME automatically
Refs #358
2016-12-13 15:29:15 -06:00
Thadeus Fleming
fb1925e0d8 Use std::cerr instead of std::cout for error messages 2016-12-10 11:49:44 -06:00
Derek Bankieris
150ea9f094 Remove double include of S_overrides.mk
Refs #360
2016-12-07 14:19:52 -06:00
Derek Bankieris
3600e3880a Infer TRICK_HOME automatically
Refs #358
2016-11-30 14:12:34 -06:00
Derek Bankieris
9fa76d8e78 Use std::strerror to report system call errors
Refs #357
2016-11-30 13:25:52 -06:00
Derek Bankieris
4d7ea87a43 Fix typo
Refs #355
2016-11-30 11:47:56 -06:00
Derek Bankieris
9fdb5d4c51 Merge input and error streams for plotting apps
Refs #355
2016-11-29 15:59:36 -06:00
Derek Bankieris
d72a09fef7 Add ability to clear all variables from a DR group
Don't let "sys.exec.out.time" be removed

Refs #350
2016-11-29 13:38:32 -06:00
Derek Bankieris
d859ac8453 Add funciton to remove all data record groups
Refs #350
2016-11-29 11:47:10 -06:00
Derek Bankieris
4281b92141 Fix MonteMonitor
Refs #354
2016-11-29 11:28:15 -06:00
Derek Bankieris
ac3360e87f Add ability to remove variable from data recording
For the record, I'd like to point out that many of the DataRecordGroup
functions shouldn't be called after init, but we don't prevent anyone
from doing so. Bad Trick!

Refs #350
2016-11-18 08:53:24 -06:00
John M. Penn
9ac0f64f10 Organize model functions and prototypes. Refs #338 2016-11-17 16:04:07 -06:00
Alex Lin
ecc7ac4fc3 Merge pull request #346 from jubalh/master
Remove trailing whitespaces
2016-11-08 09:18:39 -06:00
Michael Vetter
18f0d7e871 Remove trailing whitespaces
Makes it easier to edit the files. So if we press 'end of line' we are
really at the end of line.
2016-11-08 10:25:07 +01:00
Derek Bankieris
eedd0783cd Replace multiple radian units with single instance
One of the constructor parameters enables automatic creation of
SI-prefixed versions of the root unit, which obviates the need to
create them individually.

Refs #345
2016-11-07 08:22:55 -06:00
Derek Bankieris
2248b5bcfa Remove unused variables. Normalize formatting.
Refs # 345
2016-11-04 15:56:51 -05:00
Derek Bankieris
de69363cbd Improve formatting
Remove trailing whitespace. Replace tabs with spaces.

Refs #345
2016-11-04 15:48:29 -05:00
Derek Bankieris
245389182d Automatically determine TRICK_HOME in makefile
Refs #344
2016-11-04 14:49:52 -05:00
Derek Bankieris
d61fe5f3c3 Removed unused file Simcom.java #343 2016-11-04 14:49:52 -05:00
Alex Lin
55db2fedb3 Create a distclean target in the sim makefile #342
distclean target added to makefile.
2016-11-03 15:20:05 -05:00
John M. Penn
0a19eeb602 Removed un-needed null pointer checks in DPX code. Ref #16 2016-11-02 15:34:06 -05:00
John M. Penn
1f75034da2 Merge branch 'master' of https://github.com/nasa/trick 2016-11-02 14:22:08 -05:00
John M. Penn
99c8b11709 Fix a memory leak in VariableServerThread_commands. Ref #333 2016-11-02 14:12:31 -05:00
Alex Lin
d875f837f2 ICG produces non-compilable io_* code for this weird example #334
When saving the list of namespaces and classes a particular type is contained in
we have to save the class name and any template args it includes separately.  This
allows us to mangle the names easier.  And we now search for type names to see
if they follow this pattern template_name<template_args>::embedded_class.  If
we are using a template embedded class we need to create attributes for the embedded class.
2016-11-02 13:56:40 -05:00
John M. Penn
8ad462cd1c Improve organization of Cannon sim files. Ref #338 2016-11-01 18:16:26 -05:00
Derek Bankieris
664797e391 Move one-time-use variables into their call site #341 2016-10-31 10:00:48 -05:00
Derek Bankieris
29b0d2d223 Alex doesn't like auto #341
Granted, there are times you shouldn't hide the type.
2016-10-31 09:51:44 -05:00
Derek Bankieris
5898f3fdec Improve loop efficiency #341
Calling getTemplateArgs() every iteration is wasteful. This should
be done once outside of the loop. Even better, use a foreach loop and
get rid of the index varible!
2016-10-31 09:34:24 -05:00
Derek Bankieris
bdcfbb4e3a Restore debug functions #341 2016-10-31 09:10:33 -05:00
Derek Bankieris
ef1405c3be Refactor ICG
Hey buddy. I wanted to tell you this before you heard it from someone
else...

I refactored ICG.

Now, it's gonna look a little scary at first. But I promise you'll like
it when you get used to it. It'll be fine. You can trust me. #341
2016-10-28 14:37:12 -05:00
Alex Lin
ba75f6ff37 ICG does not compile using llvm 3.9 #339
The call getRBraceLoc to find the ending source location of things is gone.  Replaced
it with getting the source range and get the end of that range.  Also the way to
get clang/llvm 3.9 to process c++11 code required some reordering of calls in main as
well as adding some more features to be turned on.
2016-10-28 13:21:21 -05:00
John M. Penn
e66fc2bbd5 Update test target because SIM_cannon_integ renamed to Sim_cannon_numeric 2016-10-27 18:11:15 -05:00
John M. Penn
906a92db66 update trick_sims test target for deleted Cannon sims 2016-10-27 17:38:14 -05:00