Commit Graph

2734 Commits

Author SHA1 Message Date
h_vogt e4af384d7b outitf.c: do not call clock() if MS Windows GUI 2012-11-07 22:17:16 +01:00
rlar 451c121dd5 improve commit `variable.c: add strict error handling' 2012-11-07 19:38:28 +01:00
dwarning b7080fdbb7 make the level switch compatible for HiSIM2 and HiSIMHV 2012-11-07 11:35:51 +01:00
dwarning 13e1a7a5b9 rm whitespaces 2012-11-07 11:33:07 +01:00
Francesco Lannutti 952f55866e remove "error.h" from Makefile.am
this file is not anymore in the "frontend" folder
and "make dist" failed to generate the tarball
2012-11-06 23:55:49 +01:00
dwarning 44786a490b fix a leak in devmodtranslate 3 terminal section 2012-11-06 20:56:27 +01:00
Francesco Lannutti a4e0cfe341 move windows specific `STRICT' definition to canonical place 2012-11-06 19:31:17 +01:00
Francesco Lannutti 1209a5b025 Makefiles, drop some CVS remnants 2012-11-06 19:18:54 +01:00
Francesco Lannutti 6b7f408ca8 avoid a compiler warning, (unused static function) 2012-11-06 19:13:54 +01:00
Francesco Lannutti 32c6a76fc2 Added datarootdir variable as usual behavior and to avoid autoconf warning 2012-11-06 10:38:44 +01:00
Francesco Lannutti 99296c9530 Solved linking error for ngsconvert after ft_stricterror patch in src/frontend/variable.c 2012-11-06 10:32:46 +01:00
Francesco Lannutti b361dee4cc fix #include <> versus "" 2012-11-05 21:34:54 +01:00
rlar 9976c1e177 XSPICE, install dlmain.c
for separate compilation of XSPICE user models
2012-11-05 21:23:52 +01:00
dwarning 082a3e92ae allow more then 4 terminal mos models in subckts 2012-11-05 18:16:55 +01:00
h_vogt d5a2a361f6 variable.c: add strict error handling 2012-11-04 14:16:27 +01:00
h_vogt 85244d0222 inpcom.c: remove bug in inp_add_series_resistor(),
prevent crash in inp_remove_ws() upon erroneous input
2012-11-04 14:15:37 +01:00
h_vogt 5c4f8946f6 inp.c: avoid crash if setparse() returns NULL 2012-11-04 14:12:03 +01:00
h_vogt d8d8cf147e spiceif.c: correct types being loaded by snload() 2012-11-03 16:24:01 +01:00
h_vogt 65b976dab7 rename commands 'savesnap', 'loadsnap' to 'snsave', 'snload'
to avoid conflict with command 'save'
2012-11-01 14:41:13 +01:00
rlar ff2138b186 hisim2, bug fix, a numerical problem in the hisim2 and hisimhv models
First seen when compiled with gcc-4.6.2 -g -O1

The macro `Fn_SZ' which boils down to
  1/2 * (x + sqrt(x*x + c*c))
was used in a context where a negative result
  blew up the following computations.
(used to compute `Egidl', which is used to
 compute exp(-1 / (Egidl + small_constant)))

For large negative values of x the computation
boils down to
  1/2 ( x + almost(|x|) )
where the summands almost cancel each other,
sometimes yielding a small negative result.

small_constant was too small to avoid a big
  result for -1/(Egidl + small_constant)
yielding an `inf' during the exp() computation,
which was later multiplied with a `0'
  yielding a NaN,
which was carried forward
  during the rest of computations.

Because the error of the cancellation scales
with the magnitude of x, no larger `small_constant'
could have avoided the problem.

Presumably the problem was amplified
  by a mixture of precisions (double versus extended float)
  of intermediate values.
(the program wasn't compiled for sse)

( x was -2.812500e+06,
  c was  1.000000e-02,
  Fn_SZ result was -1.853095e-11

  thus the cancellation remainder
  was of relative size
    6.6e-18
  which is approximately
    2^-57
  and thus more accurate
   as a `double float' could have delivered
)
2012-11-01 23:04:51 +01:00
rlar 0c0f21faaf hisim2, use TMALLOC, funcall, and NULL casts 2012-11-01 22:53:43 +01:00
rlar a7a2ff0f7b hisim2, fix NevalSrc(), Nintegrate() redeclaration 2011-05-22 10:16:08 +00:00
h_vogt a57361333a inpcom.c: add series resistor to each inductor with option rseries=1m 2012-10-29 23:13:20 +01:00
h_vogt c53f74ee5f com_ghelp.c: better message for help under Windows 2012-10-29 23:09:35 +01:00
Francesco Lannutti 08ec219417 remove all .cvsignore files 2012-10-26 18:30:14 +02:00
Francesco Lannutti 1dc70189a7 remove compilation warnings (type casts) 2012-10-26 18:04:44 +02:00
Francesco Lannutti d8b2ac56a3 rename "bsim3soi" device to "bsimsoi" 2012-10-26 17:56:59 +02:00
rlar 2142d39506 remove adms3 #2/2, files 2012-10-25 18:54:09 +02:00
rlar ba131a5077 remove adms3 #1/2, code
due to license issues, and with the aim to approach the next
  ngspice release 25
we have to move this over to a development branch
2012-10-25 18:54:09 +02:00
dwarning e75fdab962 hisim2 update to version 2.6.1 2012-10-24 08:54:31 +02:00
Francesco Lannutti fd4c492562 white space changes 2012-10-22 23:06:25 +02:00
Francesco Lannutti 5f34eb2729 white space changes 2012-10-22 23:06:25 +02:00
Francesco Lannutti c23bd59c44 removed ancient PARALLEL_ARCH feature
removed variables
  ARCHme
  ARCHsize

removed functions
  SMPcombine()
  SMPcCombine()
  CKTpartition()

removed files
  spcombin.c
  cktpartn.c

removed struct slots
  STATcombineTime
  STATtranCombTime
  STATacCombTime
  GENowner
  <MODEL>owner
2012-10-22 23:06:25 +02:00
Francesco Lannutti cb0ff8049a white space changes 2012-10-22 23:06:25 +02:00
Francesco Lannutti 3342f58149 bsim3v1/ChangeLog, bsim4v4/ChangeLog: cleanup 2012-10-22 23:06:25 +02:00
rlar a394d79c56 use utf-8 encoding 2012-10-20 21:27:15 +02:00
rlar 2bcadae16c missing newline at end of file 2012-10-20 19:49:10 +02:00
rlar 5d1bc8e55d Changed line-ending from DOS to UNIX 2012-10-20 19:48:48 +02:00
h_vogt 0853c374a1 inpcom.c: require parentheses in ternary functions if numparam
parser is involved (no B sources)
2012-10-17 22:28:49 +02:00
rlar 15606cf281 com_print(), fix a memory leak 2012-10-17 19:51:30 +02:00
rlar 99b0e78c84 DCtrCurv(), fix a memory leak 2012-10-17 19:39:30 +02:00
rlar f038d59fbe mkfnode(), fix a memory leak 2012-10-17 19:39:02 +02:00
rlar 31fa48cf17 com_write(), com_write_sparam(), fix a big memory leak 2012-10-15 20:55:55 +02:00
h_vogt c6e631f30a fourier.c: rename stored vectors 2012-10-15 18:37:07 +02:00
h_vogt ae25f54709 inpcom.c: plug small memory leak 2012-10-15 18:35:12 +02:00
rlar 0336e31c57 vector.c, rewrite vec_basename(), FIXME !
This rewritten code is functionally equivalent to the previous code,
yet the result is queer,
because the char *v_name slot of struct dvec is read
beyond its terminating '\0'

Is there indeed some code in ngspice which creates
v_name strings with an embedded '\0' ?
2012-10-13 19:09:49 +02:00
rlar ebc50b8639 inpcom.c, rewrite 2012-10-13 16:48:15 +02:00
h_vogt 339a002c55 fourier.c: output also to vector feature request tracker no. 3575841 2012-10-13 15:56:19 +02:00
rlar 374b716fdd fourier.c: remove even more memory leaks 2012-10-13 13:25:00 +02:00
rlar a4e167a657 inpcom.c, use strchr() in favour of strstr() 2012-10-13 12:27:20 +02:00
rlar 3b2b130177 inpcom.c, inp_fix_ternary_operator_str(), use copy_substring() 2012-10-13 12:00:29 +02:00
rlar 680e45f7f3 inpcom.c, inp_fix_ternary_operator_str(), rewrite 2012-10-13 11:47:22 +02:00
rlar 9352a4b72d inpcom.c, get_instance_subckt(), more carefull when there is trailing whitespace 2012-10-13 11:31:37 +02:00
rlar f61f323be0 inpcom.c, get_instance_subckt(), rewrite 2012-10-13 11:31:37 +02:00
h_vogt 2754771a61 fourier.c: remove memory leaks 2012-10-13 11:21:29 +02:00
rlar 7f0065e7fb inpcom.c, make use of copy_substring() 2012-10-13 11:03:52 +02:00
rlar 69bf624097 inpcom.c, rewrite 2012-10-13 11:02:34 +02:00
rlar 3f4e2eed49 inpcom.c, bug fix in inp_get_subckt_name() 2012-10-13 10:45:09 +02:00
rlar 021a5dd871 inpcom.c, rewrite 2012-10-12 19:23:46 +02:00
rlar e0b796f3c5 inpcom.c, rewrite 2012-10-12 18:10:52 +02:00
rlar 3085c471ac inpcom.c, cleanup 2012-10-12 17:58:05 +02:00
rlar dbf288bae7 inpcom.c, fix a bug
which was introduced in commit
  skip-ws, #5/6, unify macro versions, obj not invariant
where the SKIP.*back.* macros have been unified

FIXME, the check for `\0' in the backwards direction if of course nonsense.
These backward functions either shall not check it at all (being optimistic),
or they shell check against a start of string pointer.
2012-10-11 19:33:32 +02:00
rlar caf50ba4d8 inpcom.c, cleanup 2012-10-10 20:48:42 +02:00
h_vogt 3ca1235602 gnuplot.c: improve scaling of y axis 2012-10-09 19:47:24 +02:00
rlar 2b72fbbc5e skip_ws(), #2/2, drop macros, obj-invariant 2012-10-08 17:48:27 +02:00
rlar 9f3f794ced skip_ws(), #1/2, use functions instead of macros 2012-10-08 17:28:52 +02:00
rlar 701942cebf skip-ws, #6/6, unify macro versions, obj-invariant
checked for object file invariance
2012-10-07 21:53:42 +02:00
rlar 532ff76dac skip-ws, #5/6, unify macro versions, obj not invariant 2012-10-07 21:53:29 +02:00
rlar 6a5f234519 skip-ws, #4/6, use macros, obj-invariant
checked for object file invariance
2012-10-07 21:52:54 +02:00
rlar 4bf52410fb skip-ws, #3/6, introduce macros, obj-invariant
checked for object file invariance
2012-10-07 21:52:35 +02:00
rlar e3b5ff94c5 skip-ws, #2/6, prepare for rewrite, obj-invariant
checked for object file invariance
2012-10-07 21:52:22 +02:00
rlar 841db86e00 skip-ws, #1/6, prepare for rewrite, obj-invariant
checked for object file invariance
2012-10-07 21:52:09 +02:00
h_vogt 996dedaa71 inpcom.c: remove cccs from F, ccvs from H source 2012-10-07 17:12:42 +02:00
h_vogt e69f50270d inpcom.c: correct replacement of vccs, vcvs in E, G-sources
search for 'par(' instead of 'par'
2012-10-07 15:19:28 +02:00
rlar 01ed0ac5d9 com_fft(), com_psd(), com_spec(), cleanup storage more thoroughly
use free_pnode() instead of free_pnode_o()
drop free_pnode_o()
2012-10-06 21:07:27 +02:00
rlar dfe8342b91 invoke com_remcirc() in com_quit() 2012-10-06 15:20:17 +02:00
rlar c7717e37fc cleanup, whitespace 2012-10-06 12:30:31 +02:00
rlar 7acc91157a cleanup, drop unused macros 2012-10-06 12:16:07 +02:00
rlar eb931dc01a cleanup, ngspice/config.h is already in ngspice/ngspice.h, #2/2 2012-10-06 12:12:17 +02:00
rlar 11579d9369 cleanup, ngspice/config.h is already in ngspice/ngspice.h, #1/2 (easy ones) 2012-10-06 12:12:08 +02:00
h_vogt c336f5ec9d outif.c, typesdef.c, sim.h: correct labeling of cap, cur, and charge data 2012-10-03 15:01:36 +02:00
h_vogt 7d82367666 b3ld.c, b4ld.c, b3v32ld.c: enable capacitance calculation during dc sweep 2012-10-03 14:28:19 +02:00
h_vogt 705e130868 b3v32.c: make additional parameters accessible by @m1[par] 2012-10-01 23:03:41 +02:00
h_vogt c0bc0de4b5 prototype for controlled_exit() 2012-10-01 23:02:26 +02:00
rlar 7a65ea0318 com_write_sparam(), cleanup storage more thoroughly (`wl_sparam') 2012-10-01 21:28:48 +02:00
rlar 98b38556aa com_alter_common(), cleanup storage more thoroughly (on error) 2012-10-01 21:09:26 +02:00
rlar 124f0f4727 com_write(), com_write_sparam(), com_cross(), cleanup storage more thoroughly 2012-10-01 21:03:53 +02:00
rlar 7b2c9db809 com_psd(), cleanup storage more thoroughly (`win') 2012-10-01 19:59:43 +02:00
rlar a891e7dc9c com_print(), cleanup storage more thoroughly 2012-10-01 19:44:49 +02:00
rlar 0f089d2bd6 com_compose(), cleanup storage more thoroughly 2012-10-01 18:31:02 +02:00
rlar 35c0e9eca3 variable rename, unify the source
checked for object file invariance
2012-10-01 17:59:40 +02:00
rlar f95aaaafc1 com_print(), com_cross(), use for(;;) loops 2012-10-01 17:53:01 +02:00
h_vogt fe828c5081 bsim3, make additonal parameters accessible with @m[par] 2012-09-30 23:49:18 +02:00
rlar 44c1380281 variable rename, unify the source
checked for object file invariance
2012-09-30 23:26:26 +02:00
rlar bc89379aff fourier(), use for(;;) loops 2012-09-30 23:11:26 +02:00
rlar d06265142d variable rename, unify the source
checked for object file invariance
2012-09-30 23:10:49 +02:00
rlar e0d64e14cc bug fix, fourier(), prevent endless loop when processing unexpected vectors 2012-09-30 23:10:38 +02:00
rlar e712080579 com_compose(), use for(;;) loops 2012-09-30 22:50:23 +02:00
rlar 959b62e14d variable rename, unify the source
checked for object file invariance
2012-09-30 22:36:12 +02:00
rlar 5a58281e7b com_spec(), use for(;;) loops 2012-09-30 22:22:28 +02:00
rlar 5102735df9 variable rename, unify the source
checked for object file invariance
2012-09-30 22:22:20 +02:00
rlar 5826f3c0e6 com_fft(), com_psd(), use for(;;) loops 2012-09-30 21:44:28 +02:00
rlar 26bbb39a68 variable rename, unify the source
checked for object file invariance
2012-09-30 21:43:16 +02:00
rlar f52ae6eccd bug fix, invalid read when the title line is the empty 2012-09-30 18:38:36 +02:00
dwarning 2506fe3858 changed the #include order - ngspice.h must be first
because icc complains about declaration visibility of mmsghdr struct
2012-09-29 20:44:12 +02:00
dwarning ebfeaf72f1 bjttemp.c: prevent uninitialized variables 2012-09-29 17:57:35 +02:00
rlar 119be60fdc polish a very old and unused artifact in WANT_SENSE2 2012-09-27 20:43:27 +02:00
rlar ae5de92c69 cleanup db_print_pnode_tree() 2012-09-27 19:49:42 +02:00
rlar 44e7f7f7bd bug fix, dvec in a `define' can't be member of any plot 2012-09-27 19:46:06 +02:00
rlar 0280a49b69 bug fix, avoid segfault when the refered plot is still empty 2012-09-27 19:46:06 +02:00
h_vogt 986f9b7535 grid.c: prevent overflow of div_list 2012-09-26 21:12:26 +02:00
h_vogt e096101133 ifeval.c: reduce fudge factor for div and atanh 2012-09-26 21:00:40 +02:00
h_vogt 0bdc33db40 grid.c: prevent crash if real low and high values are close 2012-09-26 20:58:58 +02:00
h_vogt 68c4de76b7 new option noopac, don't do op simulation before ac if circuit is linear
May simplify ac simulation of passive RLC networks
(No need to add series resistors in Ls, allows to C inseries)
2012-09-26 16:59:59 +02:00
rlar 998c7f2934 disable some more cleanup code in com_quit()
destroy_ivars() is reported to freeze
2012-09-25 21:31:45 +02:00
rlar ee0b602dc4 subckt.c, cleanup, use `for' instead of `while' 2012-09-22 22:12:56 +02:00
rlar fe1acd3757 src/frontend/** remove superfluous `return' invocations 2012-09-22 19:33:55 +02:00
rlar ab98f03622 src/frontend/** whitespace, indentation, ...
checked for object file invariance on linux
2012-09-22 19:33:50 +02:00
rlar d1d4eb11a5 invoke cleanup functions in com_quit()
trying to get the valgrind reports down.
2012-09-22 10:53:05 +02:00
rlar 71240d19be free spice_init_devices() allocated memory in com_quit() 2012-09-21 21:19:44 +02:00
rlar 811bf5664a destroy `const' plot in com_quit() 2012-09-21 21:19:44 +02:00
rlar 7a5eeb2d9c drop a superfluous cast 2012-09-21 21:19:44 +02:00
dwarning fb23e1f024 correct the diode temperature model 2012-09-20 21:06:34 +02:00
rlar c0e2d4abef src/frontend/**, whitespace,
object files will change, due to __LINE__ usage
2012-09-20 20:32:02 +02:00
rlar 7454a6d486 src/frontend/**, whitespace, indentation, ...
untabify
delete-trailing-whitespace
braces
...

checked for object file invariance on linux
2012-09-20 20:30:53 +02:00
rlar f3b5336d3a cleanup some macros, try to be more careful 2012-09-19 20:16:27 +02:00
rlar ec1a71249a fix ownership of `cp_promptstring' and `cp_program' 2012-09-15 14:58:39 +02:00
rlar 198604f605 define.c, plug a memleak in com_undefine() 2012-09-13 21:52:03 +02:00
rlar 6a3c20706a define.c, cleanup 2012-09-13 21:21:46 +02:00
rlar b68259ff2d define.c, cleanup 2012-09-13 21:21:08 +02:00
rlar 1fbc4d62cc define.c, whitespace cleanup 2012-09-13 21:18:02 +02:00
rlar 38ce3b6142 define.c, bug fix, when undefining more than one udfunc 2012-09-13 21:05:56 +02:00
rlar adc9ee09ce api change for ngdirname() to fix a memory leak
ngdirname did `own' the returned string.
now the invoker is responsible for the returned string.

note, this is contrary to the POSIX dirname() implementation,
   which *might* return pointers to statical allocated memory.
2012-09-13 20:07:33 +02:00
h_vogt 7c9b90c9ea XSPICE lcouple: remove unused cm_analog_integrate 2012-09-11 21:29:16 +02:00
h_vogt cb220b2d6f XSPICE core: remove memory leak 2012-09-10 23:40:40 +02:00
h_vogt 8d374157fe XSPICE square: remove memory leak, initialize phase1 2012-09-10 22:52:10 +02:00
h_vogt d6698c5f6c XSPICE square: indentations 2012-09-10 22:20:41 +02:00
h_vogt 2379bd577a XSPICE triangle: remove memory leak remove initialization error for phase1 FIXME: there are still more initialization errors 2012-09-09 19:07:29 +02:00
h_vogt 8ece02a1cd XSPICE triangle: indentations 2012-09-09 17:56:12 +02:00
h_vogt feb545d8a7 XSPICE oneshot: remove memory leak remove using uninitialzed variable old_clock correct waveform shape by using permanent breakpoints 2012-09-09 16:55:10 +02:00
h_vogt 36898f9921 indentations 2012-09-09 16:44:58 +02:00
h_vogt bcbd506ccc XSPICE sine: out-of-bounds removed 2012-09-08 01:38:25 +02:00
h_vogt 10d97d222e XSPICE sine source: memory leak removed (bug no. 3564166) 2012-09-08 00:45:59 +02:00
h_vogt 9f8c73d271 cktdest.c: reset for XSPICE allocated memory (not yet complete) 2012-09-07 23:50:38 +02:00
h_vogt 5ce51f148e XSPICE filesource: remove segfault with op before tran 2012-09-07 23:48:09 +02:00
h_vogt 9de9336581 cktload.c, indentations 2012-09-02 16:11:46 +02:00
h_vogt 4e45f4cba0 inp.c: unify syntax of .save and save commands: allow node1 and v(node1), v2#branch and i(v2), @dev[param] 2012-08-30 11:03:48 +02:00
h_vogt 0efaeac8b4 evtqueue.c: plug memory leak 2012-08-27 10:42:12 +02:00
h_vogt 417d109764 resask.c: avoid segfault if @R[i] is asked before analysis is run 2012-08-27 00:12:14 +02:00
h_vogt 9eaff645f5 vectors.c, resask.c: indentation 2012-08-26 23:32:21 +02:00
h_vogt a5a1029998 d_source: Use STATIC_VAR_TABLE to save memory 2012-08-25 13:39:27 +02:00
rlar 3d7ab6a297 cleanup keyword databases on proram termination 2012-08-23 21:19:15 +02:00
rlar 80bc975e33 plug a memory leak in inp_spsource/inp_nutsource (deck title string) 2012-08-23 21:13:44 +02:00
rlar 84283b43d4 cleanup ivars() related globals on program termination 2012-08-23 21:09:25 +02:00
h_vogt f4ad29a17c d_source: allow multiple instances 2012-08-22 23:14:26 +02:00
rlar 83c99bece4 cleanup wallace arrays on program termination 2012-08-22 22:21:33 +02:00
rlar 590fc543f8 avoid error messages when finally closing the display device.
these messages creeped in with commit
  2012-08-19 18:58:31
  "plug memory leak in x11.c"

when the "printf" device Close and Update
 functions might be invoked on program termination.

use the silent "nop" implementation
instead of the error reporting "nodev" implementation
2012-08-20 21:26:08 +02:00
h_vogt 7191fdce63 d_source cfunc.mod: plug memory leaks 2012-08-20 08:54:26 +02:00
h_vogt 488bc6a8c8 bug no. 3456221: new d_source model 2012-08-19 21:36:33 +02:00
rlar b5b0ec7302 cleanup, white space changes 2012-08-19 21:36:31 +02:00
rlar 6c01089be1 plug memory leak in x11.c
try to obey the Xt toolkit protocol when closing widgets and application
2012-08-19 19:18:34 +02:00
h_vogt cb42989204 mifgetvalue.c: need a copy to allow freeing token 2012-08-19 15:49:24 +02:00
rlar 789edee376 rewrite inp_list() avoid duplicate code 2012-08-19 14:04:37 +02:00
rlar c9e2a21a9c reimplement tcl_vfprintf() 2012-08-19 12:53:55 +02:00
rlar c4d0feb6cc bug fix, out_send() erroneously interpreting printf %-style sequences 2012-08-19 12:20:33 +02:00
rlar b9b9f6fd1c cleanup (checked for code invariance) 2012-08-19 12:14:22 +02:00
dwarning 5ca213b481 part of temperature level=3 model 2012-08-18 21:10:48 +02:00
rlar 67132108ad out_printf() is not supposed to be a preprocessor macro 2012-08-18 18:40:45 +02:00
h_vogt 0af75f3bd9 subckt.c, mif_inp2.c: plug XSPICE setup memory leaks 2012-08-18 18:31:23 +02:00
rlar d4ced47e8e drop out_pbuf, which was an ancient workaround
obviously an old implementation of out_printf()
  has been unreliable.
2012-08-18 18:27:13 +02:00
rlar 0825c10471 bug fix, print complex yet real valued frequency
when printing a complex frequency vector, yet with real value
  some left over nonsens was printed instead of the actual real value.

this bug was introduced in commit:
  Date:   Thu Jan 15 21:08:09 2009 +0000

  Improvements in vector derivative computation and new functions to
  compute group delay and moving average. From espice (A. Roldan).
2012-08-18 17:10:06 +02:00
h_vogt b02a497490 mif_inp2.c, subckt.c: plug memory leaks at XSPICE setup 2012-08-15 23:11:07 +02:00
rlar 9390a9a9ec rewrite com_quit()
emphasize user confirmation

and if we are going to remove dangling circuits,
then do so unconditionally
2012-08-15 20:15:15 +02:00
rlar be183407cd cleanup (checked for code invariance) 2012-08-15 19:18:15 +02:00
rlar ae6a16e3e4 plug a memory leak when executing `shell' 2012-08-14 21:00:21 +02:00
rlar fa81e9d007 plug a memory leak when (un)setting variables 2012-08-14 20:39:11 +02:00
rlar 64139a243c spiceif.c, cleanup (checked for code invariance) 2012-08-14 20:38:25 +02:00
rlar 0c230b2970 spiceif.c, cleanup (checked for code invariance) 2012-08-12 20:28:42 +02:00
rlar 10a9ae32c5 options.c cleanup 2012-08-12 12:48:27 +02:00
rlar a2f58da0d0 options.c, whitespace 2012-08-12 12:43:09 +02:00
rlar e93960f9ed cleanup, if_options() will copy() anyway 2012-08-12 12:25:00 +02:00
rlar 7126dd6f1d display.c, cleanup 2012-08-08 18:54:52 +02:00
rlar 0beb95757f cancer of the semicolon 2012-08-07 21:20:36 +02:00
rlar d50ffdd987 swallow warnings 2012-08-06 19:50:23 +02:00
rlar 1a2477bdcc avoid `meas' syntax error causing segfault
Invalid meas crashes ngspice with SIGSEV - ID: 3554330
http://sourceforge.net/tracker/?func=detail&aid=3554330&group_id=38962&atid=423915
2012-08-06 19:42:49 +02:00
rlar 46980f2cc6 plotit.c #9/9, whitespace 2012-08-05 21:41:25 +02:00
rlar 4803d8bba2 plotit.c #8/9, braces 2012-08-05 21:41:25 +02:00
rlar 6a334da2b4 plotit.c #7/9, braces 2012-08-05 21:41:25 +02:00
rlar f587553217 plotit.c #6/9, braces 2012-08-05 21:41:25 +02:00
rlar 088e88d9b2 plotit.c #5/9, localize 2012-08-05 21:41:25 +02:00
rlar 5f1387892c plotit.c #4/9, line wrap 2012-08-05 21:41:25 +02:00
rlar ed4ad1c0dd plotit.c #3/9, drop some comments 2012-08-05 21:41:25 +02:00
rlar 5c43e8f2fc plotit.c #2/9, emphasize maximize/minimize 2012-08-05 21:41:25 +02:00
rlar 406fc29007 plotit.c #1/9, think positive 2012-08-05 21:41:25 +02:00
h_vogt 11ae043c3d com_measure2.c: enable 'meas dc' without 'from' and 'to' given
measure.c: no error printout during autostop
2012-08-05 20:03:00 +02:00
rlar d6ba5e5b3f cleanup free_struct_variable() 2012-08-05 12:22:47 +02:00
rlar 75c59a26fa variable.c, cleanup (mostly whitespace) 2012-08-05 12:22:47 +02:00
dwarning 99b167b272 correct alter of mos geometries for binned models 2012-08-05 12:11:16 +02:00
rlar 51271d2a0b cp_oddcomm(), plug a memory leak 2012-08-04 22:27:04 +02:00
h_vogt acfc7a2a27 remove memory leaks 2012-08-04 19:09:13 +02:00
dwarning 2516a118a3 indentation 2012-08-04 16:24:38 +02:00
rlar 713091ea22 wlist #3/3, whitespace 2012-08-04 11:40:35 +02:00
rlar fe5ac28b92 wlist #2/3, cleanup 2012-08-04 11:40:35 +02:00
rlar 406dcc3519 wlist #1/3, cleanup 2012-08-04 11:40:35 +02:00
h_vogt 05437b1d48 inpcom.c: safely uncomment unused subcircuits (top level only)
if they contain further nested subcircuits
2012-08-03 22:42:33 +02:00
rlar 9ed7ce4e9e wlist.c, `const' ness 2012-08-03 21:46:13 +02:00
rlar e4c7a8df32 use wl_find() 2012-08-03 20:48:11 +02:00
rlar cf2a0f3df3 cleanup, linewrap 2012-08-03 20:43:12 +02:00
rlar 191ae9ea90 cleanup, char 0 2012-08-03 20:43:10 +02:00
rlar 5a69b9efc4 cleanup, void return 2012-08-03 20:43:06 +02:00
rlar ef37252155 lexical, use wl_append_word() 2012-08-03 20:24:58 +02:00
rlar 62a4ee77d5 lexical #6/6, whitespace 2012-08-03 20:20:18 +02:00
rlar ea558fbc7f lexical #5/6, cleanup 2012-08-03 20:18:17 +02:00
rlar aa188c0766 lexical #4/6, parentheses and braces 2012-08-03 20:16:47 +02:00
rlar c73c0f4318 lexical #3/6, rewrite 2012-08-03 20:12:58 +02:00
rlar 5656203a6c lexical #2/6, linewrap 2012-08-03 20:12:19 +02:00
rlar 5d245c9dab lexical #1/6, cleanup 2012-08-03 20:09:34 +02:00
h_vogt 96d2ff96e0 alloc.c: exlude controlled_exit if not MS Windows
not available in some tests in cmaths and executable like ngproc2mod
2012-08-03 08:28:50 +02:00
rlar 64d00a6b43 lexical #3/3, collapse append(NULL) into cp_ccom()
the sequence
   orig_wlist = wlist;
   append(NULL);
   cp_ccom(wlist, ...);
 is transformed.

 expressions to care about in cp_ccom()
    C1 :=  (wlist->wl_next != NULL)
    C2 :=  (wlist->wl_word != NULL)
    C3 :=  wl_length(wlist)

    D1 :=  (orig_wlist != NULL)
    D2 :=  (orig_wlist->wl_word != NULL)
    D3 :=  wl_length(orig_wlist);

 cases and their significance in cp_ccom():
    orig_wlist = NULL;
    wlist = wl_cons(NULL, NULL);
      C1 == false
      D1 == false
      C2,C3 dont care

    orig_wlist = wl_cons(E1, wl_cons(E2, ... wl_cons(En, NULL)))
    wlist = wl_cons(E1, wl_cons(E2, .... wl_cons(En, wl_cons(NULL, NULL))))
     C1 == true
     D1 == true
     C2 === D2
     C3 === D3 + 1
2012-08-02 18:55:54 +02:00
rlar fec5b00a0d lexical #2/3, fix memory leaks 2012-08-02 18:55:54 +02:00
rlar 042311d0c3 lexical #1/3, move append(NULL) invokations into position 2012-08-02 18:55:54 +02:00
h_vogt 67e0cf0608 undo controlled_exit: not compatible with ancient tests in cmath under LINUX 2012-08-01 22:10:13 +02:00
rlar 1195498978 lexical #19/19, rewrite 2012-07-31 20:49:34 +02:00
rlar 5b67ecda79 lexical #18/19, rewrite
`cw' won't be looked at, thus the append + removal can be dropped
  `wl_word' is already NULL
2012-07-31 20:49:34 +02:00
rlar f990e517b5 lexical #17/19, rewrite 2012-07-31 20:49:34 +02:00
rlar fa9be4336a lexical #16/19, transform append --> append(word) 2012-07-31 20:49:34 +02:00
rlar 43a6d59c72 lexical #15/19, drop `delayed' which is never zero ... 2012-07-31 20:49:33 +02:00
rlar 47b5e9576d lexical #14/19, drop `delayed = 0' wherever its effect isn't visible
without effect, because we return or will overwrite it anyway
2012-07-31 20:49:33 +02:00
rlar 01df4e9437 lexical #13/19, delay `append'
delay its execution, until
    either `wlist' or `cw' will be accessed,
  or
    a return or goto nloop is inevitable
2012-07-31 20:49:33 +02:00
rlar cff6188fe3 lexical #12/19, use `append'
some `assumption' are no longer valid
2012-07-31 20:49:32 +02:00
rlar 5ad8382cf1 lexical #11/19, aproach `append' here 2012-07-31 20:49:32 +02:00
rlar d61f3c10a0 lexical #10/19, split off `append' from `newword' 2012-07-31 20:49:32 +02:00
rlar af0a0c2c03 lexical #9/19, aproach the `append'
cw has never been NULL here,
   because we used to survive an update of cw->wl_next here

wlist hasn't been NULL either,
  because there is no place where wlist becomes NULL without
  setting cw to NULL as well. yet cw isn't NULL (see above)
aproach the `append'
2012-07-31 20:49:31 +02:00
rlar 74cc38f67a lexical #8/19, express where `wlist' and `cw' start being != NULL 2012-07-31 20:49:31 +02:00
rlar 3cbc4b0773 lexical #7/19, express verbosely where `wlist' and `cw' are NULL 2012-07-31 20:49:31 +02:00
rlar ecb2eec279 lexical #6/19, express cp_ccom() property 2012-07-31 20:49:31 +02:00
rlar 3b575d5e3d lexical #5/19, collapse into `newword' 2012-07-31 20:49:30 +02:00
rlar 348dc2d7d1 lexical #4/19, the `else' can take that job (unconditionally) 2012-07-31 20:49:30 +02:00
rlar 80191f3d44 lexical #3/19, attach and instantly remove a NULL wl_word here
this modification is faithful iff cw != NULL  and  cw->wl_next == NULL
  cw != NULL because we have just survived an update of cw->wl_word
  cw->wl_next == NULL is witnessed by:
    1) cw either NULL or pointing to a wl_cons(,NULL)
    2) cw not being modified, and no wl_next being modified
    3) check of all function invocations with wlist/cw argument
         not to modify any wl_next slot
which are:
  1) cp_ccom(wlist, ...)
  2) wl_free() always followed by goto nloop, which does a cw = wl_cons(,NULL)

and cp_ccom() doesn't modify any wl_next slot

the first part of the patch is intentionally similar to newword
`i' and `buf' can be modified here, because we will inevitably `goto done'
attach and instantly remove a NULL wl_word here
2012-07-31 20:49:30 +02:00
rlar ddebb63425 lexical #2/19, rewrite the `else if' 2012-07-31 20:49:29 +02:00
rlar f2f43bcce7 lexical #1/19, use wl_cons 2012-07-31 20:49:29 +02:00
rlar f36772419a Revert "cleanup, use wl_cons()"
This reverts parts of commit 7a7250cdbd.
There is a cleaner way to rewrite lexical.c
2012-07-31 20:48:01 +02:00
h_vogt b85f6bbc7d controlled_exit() instead of exit() 2012-07-31 17:54:51 +02:00
h_vogt 207adefcda evtprint.c: no node data: error message instead of seg fault 2012-07-30 23:32:54 +02:00
rlar 64b8dfc570 use wl_delete_slice() 2012-07-29 13:11:43 +02:00
rlar cdef8aa10e implement wl_delete_slice() 2012-07-29 13:11:42 +02:00
h_vogt d793dd6a61 variable xtrtol may override the XSPICE reduction of trtol 2012-07-29 12:53:31 +02:00
rlar 26468839d4 plotit(), cleanup wordlist processing 2012-07-28 19:55:09 +02:00
rlar 608e0473d3 copy(), allow NULL argument 2012-07-28 19:53:55 +02:00
rlar b808fcec8a fix typo in the commit `use wl_find()' 2012-07-28 14:52:17 +02:00