Menu

#799 ./tests/bin/check.sh src/ngspice tests/sensitivity/diffpair.cir failure

v1.0 (example)
open-fixed
None
5
2025-09-17
2025-07-23
No

fails with commit 80d22fc802557f8068d83637be905e1536e1c2a4 (tag: ngspice-44.2)
Author: Holger Vogt holger.vogt@uni-due.de
Date: Sat Jan 11 11:55:56 2025 +0100

Prepare the bug-fix release 44.2

also tried the prebuilt windows 64

Discussion

  • Jason Pyeron

    Jason Pyeron - 2025-07-23
    Error: no data saved for Sensitivity analysis; analysis not run
    doAnalyses: not found
    
    run simulation(s) aborted
    Error: .print: no sens analysis found.
    --- diffpair.out_tmp    2025-07-22 20:38:59.878049700 -0400
    +++ diffpair.test_tmp   2025-07-22 20:38:59.775089700 -0400
    @@ -1,87 +1,16 @@
    
    
    -Using level 1.
    -Using level 1.
    -Transfer function information:
    -output_impedance_at_v(5) = 9.446843e+03
    -vcm#input_impedance = 1.793366e+06
    -
    -Transfer function information:
    -output_impedance_at_v(5) = 9.446843e+03
    -vdm#input_impedance = 8.940897e+03
    -
    
    -              simple differential pair - CM and DM dc sensitivity
    -0      1.851978e-02    -1.909518e-08   -1.720287e-08   -3.819037e-08
    -
    
    
    -              simple differential pair - CM and DM dc sensitivity
    -0      4.549980e+16    -9.547591e-09   -1.273012e-08   -1.339677e+02
    -
    
    
    -              simple differential pair - CM and DM dc sensitivity
    -0      -1.909518e-08   -1.487980e-03   1.410876e-04    -6.960475e-01
    -
    
    
    -              simple differential pair - CM and DM dc sensitivity
    -0      -1.143803e-02   -6.365061e-09   4.684669e+00    -1.909518e-08
    -
    
    
    -              simple differential pair - CM and DM dc sensitivity
    -0      -1.909518e-08   4.684670e+00    2.497064e-01    -1.851978e-02
    -
    
    
    -              simple differential pair - CM and DM dc sensitivity
    -0      6.546832e-09    5.898047e-09    1.309366e-08    -4.549980e+16
    -
    
    
    -              simple differential pair - CM and DM dc sensitivity
    -0      3.273416e-09    4.364555e-09    1.339677e+02    6.546832e-09
    -
    
    
    -              simple differential pair - CM and DM dc sensitivity
    -0      1.487980e-03    -1.410877e-04   6.960475e-01    1.143803e-02
    -
    
    
    -              simple differential pair - CM and DM dc sensitivity
    -0      2.182277e-09    -4.684669e+00   6.546832e-09    6.546832e-09
    -
    
    
    -              simple differential pair - CM and DM dc sensitivity
    -0      -4.684670e+00   -2.497064e-01   3.308722e-18    3.534097e-22
    
    
    
    -              simple differential pair - CM and DM dc sensitivity
    -0      2.729032e-22    6.058452e-22    6.776264e+01    1.514613e-22
    
    
    
    -              simple differential pair - CM and DM dc sensitivity
    -0      2.019484e-22    -2.168404e-13   3.534097e-22    -3.705769e-18
    
    
    
    -              simple differential pair - CM and DM dc sensitivity
    -0      9.693523e-23    -1.003891e-15   -4.135903e-21   1.009742e-22
    
    
    
    -              simple differential pair - CM and DM dc sensitivity
    -0      7.623297e-15    3.029226e-22    3.029226e-22    7.623297e-15
    -
    
    
    -              simple differential pair - CM and DM dc sensitivity
    -0      3.764591e-16    -5.955700e-18   1.135960e-22    1.023387e-22
    -
    
    
    -              simple differential pair - CM and DM dc sensitivity
    -0      2.271919e-22    -6.776264e+01   5.679799e-23    7.573065e-23
    -
    
    
    -              simple differential pair - CM and DM dc sensitivity
    -0      2.168404e-13    1.135960e-22    3.705769e-18    -7.940934e-19
    -
    
    
    -              simple differential pair - CM and DM dc sensitivity
    -0      1.129377e-15    2.541099e-17    3.786532e-23    -7.623297e-15
    -
    
    
    -              simple differential pair - CM and DM dc sensitivity
    -0      1.135960e-22    1.135960e-22    -7.623297e-15   -3.764591e-16
    -
    
    
    -              simple differential pair - CM and DM dc sensitivity
    -0      3.811648e-19    -6.776264e-15   7.623297e-15    6.031558e-04
    -
    
    
    -              simple differential pair - CM and DM dc sensitivity
    -0      -6.031564e+00   6.031558e+00    -6.031558e-04   6.031564e+00
    -
    
    
    -              simple differential pair - CM and DM dc sensitivity
    -0      -6.031558e+00   -1.346892e-03   1.346894e+00    -1.346892e+00
    -
    
    
    -              simple differential pair - CM and DM dc sensitivity
    -0      1.346892e-03    -1.346894e+00   1.346892e+00    0.000000e+00
    -
    
    
    -              simple differential pair - CM and DM dc sensitivity
    -0      1.290931e-13    -1.758090e+02   4.235165e-16
    
    +Transfer function information:
    +output_impedance_at_v(5) = 9.446844e+03
    +vcm#input_impedance = 1.793369e+06
    
    +Transfer function information:
    +output_impedance_at_v(5) = 9.446844e+03
    +vdm#input_impedance = 8.941100e+03
    
     
  • Jason Pyeron

    Jason Pyeron - 2025-07-23

    34 does not work, issue introduced around version 30?

     
  • Holger Vogt

    Holger Vogt - 2025-07-23
    • status: open --> open-accepted
    • assigned_to: Holger Vogt
     
  • Holger Vogt

    Holger Vogt - 2025-07-23

    ngspice-32 is o.k., with some warnings.
    ngspice-33 - 35 segfault.
    Since ngspice-36 the simulator shows the behaviour as described above.

    After removing the .tf analyses, .sens is simulated.

     

    Last edit: Holger Vogt 2025-07-23
  • Holger Vogt

    Holger Vogt - 2025-07-23

    The offending commit is
    01ed22489 ("A check to avoid multiple entries for the same node into the .save list", 2021-10-20).
    I do not yet understand why.

    In addition it is necessary to add model->BJTintCollResistGiven = TRUE;in bjtsetup.c to avoid the crash:

            if((!model->BJTintCollResistGiven)
               ||(model->BJTintCollResist<0.01)) {
                model->BJTintCollResist = 0.01;
                model->BJTintCollResistGiven = TRUE;
            }
    
     
  • Dietmar Warning

    Dietmar Warning - 2025-07-23

    Good point, perhaps we have a similar problem in other devices too.
    E.g. the serial resistance in the diode is also set to a certain value and later we relay in diotemp.c to DIOresistGiven. Here we will not fabricate a crash but the temperature dependency for the resistor is not handled for the pathological case of non given resistor and given temp coeff's.
    I will check other devices like vdmos and vbic too.

     
  • Holger Vogt

    Holger Vogt - 2025-07-23

    Adding model->BJTintCollResistGiven = TRUE; in bjtsetup.c unfortunately will lead to several problems in our paranoia suite, 100W.cir woill fail completely.

    With current pre-master-45 it is indeed not required for running the diffpair.cir successfully with TF, TH, and sens!

     
  • Holger Vogt

    Holger Vogt - 2025-07-27

    A fix to re-allow running diffpair.cir is now on git branch pre-master-45.

    The 'make check' for the .TF still will deliver an output showing the deviations of the newly resulting output in comparison to the (old) diffpair.out. Fixinf this will require some more activity, as the code in the test/sensitivity is 20 years old, and we indeed in the meantime have some changes to the output. And make check does only do a simple text comparison.

     
  • Holger Vogt

    Holger Vogt - 2025-09-17
    • status: open-accepted --> open-fixed
     

Log in to post a comment.

MongoDB Logo MongoDB