The NGSPICE circuit simulator
This is a modal window.
The media could not be loaded, either because the server or network failed or because the format is not supported.
Formal Metadata
Title |
| |
Subtitle |
| |
Alternative Title |
| |
Title of Series | ||
Number of Parts | 150 | |
Author | ||
License | CC Attribution 2.0 Belgium: You are free to use, adapt and copy, distribute and transmit the work or content in adapted or unchanged form for any legal purpose as long as the work is attributed to the author in the manner specified by the author or licensor. | |
Identifiers | 10.5446/34364 (DOI) | |
Publisher | ||
Release Date | ||
Language | ||
Production Year | 2015 |
Content Metadata
Subject Area | |
Genre |
FOSDEM 2015125 / 150
3
5
9
11
13
14
15
16
17
18
19
20
24
26
27
28
29
30
37
41
42
44
48
50
54
62
64
65
67
68
69
71
75
78
79
82
83
84
85
86
87
88
89
90
94
96
97
103
104
105
107
108
113
114
115
117
118
121
122
123
125
126
127
129
130
131
133
136
137
138
141
142
147
148
149
150
00:00
SimulationDigital electronicsComputer simulationMultiplication signXMLSource code
00:30
Turing testTelecommunicationSource codeLine (geometry)SimulationComputer simulationInternetworkingSoftware developerStudent's t-testDigital electronicsPhysical systemComputer-aided designFunction (mathematics)System programmingDomain nameWeb pageInformationData structureInterface (computing)ModemHolographic data storageLinear mapControl flowOperator (mathematics)Variable (mathematics)Element (mathematics)Regulärer Ausdruck <Textverarbeitung>Physical systemMatching (graph theory)Acoustic shadowComputer-assisted translationMultiplication signCellular automatonQuicksortPoint cloudSoftwareMassMoment (mathematics)Sign (mathematics)Row (database)Order (biology)Computer simulationProjective planeConnectivity (graph theory)SimulationPlotterMathematical analysisOpen sourceInterface (computing)Library (computing)GodSatelliteExtension (kinesiology)FreewareWater vaporReading (process)State of matterNormal (geometry)Codierung <Programmierung>Thermal expansionSystem callGame theoryHydraulic jumpBitWhiteboardTable (information)DemosceneCodeGroup actionField (computer science)Branch (computer science)1 (number)Cloud computingStandard deviationFront and back endsElectronic mailing listSource codeDigital electronicsDifferent (Kate Ryan album)System on a chipCore dumpSource codeComputer animation
09:49
Regulärer Ausdruck <Textverarbeitung>Source codeComputer simulationData transmissionLine (geometry)Sample (statistics)Single-precision floating-point formatManufacturing execution systemBenchmarkStandard deviationImplementationRevision controlDistribution (mathematics)File formatInterface (computing)Digital electronicsSimulationSoftware developerComputer configurationDisintegrationStatement (computer science)Read-only memoryMathematical analysisSoftwareParameter (computer programming)Function (mathematics)Absolute valueUniform convergenceScripting languageLevel (video gaming)Plot (narrative)Random numberInternet service providerFront and back endsProgrammable read-only memoryContext awarenessVector spaceModul <Datentyp>Library (computing)Compact spaceNumerical analysisComputer-aided designCodeSystem programmingPoint (geometry)Linear mapPerformance appraisalPhase transitionSingle sign-onSoftware configuration managementCompilerMereologyUser interfaceMultiplicationParsingToken ringFormal grammarProcess (computing)Arithmetic meanFormal languageMoment (mathematics)CASE <Informatik>View (database)Lattice (order)Domain nameDiallyl disulfideDampingCausalityDisk read-and-write headComputer simulationSource codeMultiplication signSoftware testingMassMusical ensembleData managementSocial classDocument management systemWeightQuicksortSlide ruleINTEGRALCompilerPoint (geometry)MereologyMathematical analysisNeuroinformatikStaff (military)SummierbarkeitLogic gateDemosceneSoftware bugSystem callFunction (mathematics)Physical systemBeta functionFrequencyProduct (business)Extension (kinesiology)User interfaceGenderGroup actionCellular automatonScripting languageRevision controlDebuggerPropagatorAutonomous system (mathematics)Random number generationDerivation (linguistics)SimulationPreprocessorSoftwareSemiconductor memoryPartial derivativeTranslation (relic)Software development kitElectronic mailing listParsingParameter (computer programming)Line (geometry)Game controllerNoise (electronics)LeakParametrische ErregungMeasurementComputer fileAmerican Mathematical SocietyCompilerSource code
19:08
Computer simulationCompilerDigital electronicsSimulationModul <Datentyp>Module (mathematics)Radio-frequency identificationComplete metric spaceFamilyObject (grammar)Computer simulationRootMereologyDemosceneAngleModule (mathematics)Data structureParsingVideo game consoleQuery languageAttribute grammarCompilerSource code
20:33
SimulationOpen setProcess (computing)Digital electronicsImplementationInterface (computing)Computer simulationSource codeCellular automatonIntelRead-only memoryParallel portRing (mathematics)Mathematical analysisLinear mapSoftware developerGraphics processing unitKepler conjectureMatrix (mathematics)BefehlsprozessorArray data structureNichtlineares GleichungssystemTotal S.A.Performance appraisalBenchmarkParallel computingDifferent (Kate Ryan album)Computing platformCodeTask (computing)Type theoryPhysical systemLevel (video gaming)AnalogyRepository (publishing)Parallel portReduction of orderImplementationNetwork topologyCodeMultiplicationMaxima and minimaSimulationMassAlgorithmRight angleDigital electronicsComputer simulationMatrix (mathematics)MereologyPlotterSuite (music)Order (biology)Thread (computing)DivergenceVector spaceWebsitePhysical systemBenchmarkGraph (mathematics)Computer fileBeta functionCellular automatonNeuroinformatikSoftware testingAdditionMultiplication signEvent horizonSystem callState of matterBit rateCase moddingBitComputer animation
25:00
SimulationDigital electronicsComputer simulationStatement (computer science)WhiteboardMessage passingView (database)Scripting languagePoint (geometry)AuthorizationINTEGRALComputer animation
26:59
Digital electronicsSimulationCompilerMassGraphical user interfaceGraph (mathematics)Computer simulationMereologySubsetPoint (geometry)CollaborationismComputer animation
29:12
GoogolComputer animation
Transcript: English(auto-generated)
00:06
Hello, so I'm Francesco Lanutti from NGspice team and these guys are the other members.
00:27
So a little bit of history. SPICE is born 42 years ago at Berkeley, mainly from Larry Nagel PhD.
00:51
And NGspice started in 1999 by Paolo Nancy with the main goal of fix the original SPICE-3 code
01:12
and add new models like B-Sim-S-O-I. But now NGspice is a free open source software,
01:27
G-set on SourceForge. So now the goal is to keep the pace with the commercial tools and maybe
01:46
adding a new features. So SPICE is de facto standard for circuit simulation in both academic
02:10
and industrial field. So SPICE was designed to handle simple circuits, but now we have system
02:29
packages, system on package, system on chip and so on. And we have complex model like deep sub-migron MOSFET. So SPICE and also NGspice can handle all of this after 42 years and this
02:54
is something great. The commercial SPICE are still based on some code from SPICE-3. For
03:22
example, we expect that SPICE and SPICE-like C-mu letters will be active for the next years. So we continue to support NGspice and we also have other projects like Quacks,
04:09
SPICE team is spread across the Europe and we have three new members, Justin Fisher, Marcel Hendricks and Francesc Villa and contribution are user driven pretty much and we
04:38
try to maintain a strong code without including everything. So we test the code first and then
04:58
we create a new branch to include the code in a separate place and then we merge with the master.
05:19
NGspice was registered on Sourceforge in 2001 and now it counts 300k downloads pretty much
05:32
which are spread across these five countries. So it's a quite big community, less than Quacks
05:43
but still big and NGspice has a huge ecosystem. For example, FEGO which is a commercial tool but use NGspice for some simulation. IMOS which is sort of cloud computing from Professor
06:07
Mansunchan and it use NGspice on the cloud. We have Oscar the team which is presented by the transistor symbol, this one. It's an Indian tool for developing PCB and it use NGspice
06:35
simulator tool and then other front-end or tools that use NGspice somehow. Okay so NGspice
06:50
is divided in this way. We have the main SPICE3 core here and then we have some extension
07:02
like NGspice and tool for device simulation, a sort of T-CAD which is 1D and 2D only.
07:27
Then we have some extension to the front-end world. For example, the old Nutmeg which is the original front-end of SPICE3. So it's based on Xe11 is very poor but for plotting for base
07:51
plotting is fine. Then we have T-CoreSpice. For example, here you can use T-CoreScript to
08:04
drive NGspice compiled as a shared library and we have an interface with some T-CAD tool. On the other side we have modeling extension so we use also ADMS. We have a couple of models
08:27
included. I will show you later and then the Xspice code model toolkit. Okay this is the
08:45
list of the model which is implemented in NGspice. The bold ones are Velogay models and they are converted in C using ADMS like Quax so it's the same concept but we don't have
09:11
V-Sim 6 right now. The italic ones are the code model from Xspice. We have some
09:32
improvements to the original SPICE3 because for example we can create components which are
09:44
expression-defined like this resistor and then we have a lot of different source generator
10:03
like PBL, PAH, PALS and so on and we have non-linear control at the sources like this V-GVS and V-GGS. Then we integrated some KSpice model for example transmission line and coupled
10:33
multi-conductor line so you have to just include the model and describe the parameters.
10:47
From the semiconductor point of view we have a lot of models starting with the old Diode, then BJT, JFET and so on. We have a lot of MOSFETs until V-Sim 4 version 8 which
11:09
is the latest one and V-Sim 3 which is old but still maintained and we have some compatibility with PDKs so we maintain all the version to be able to run PDKs. We have AKV
11:31
inside in version 2.6 which is open and is in Velogate. So as I said we use a DMS by
11:47
Laurent Lemaître which convert Velogate into C and more precisely this process is divided into step. So first of all you have to use a DMS XML which is the real tool that
12:06
read the Velogate and convert it in a sort of XML3. Then NGspice has this XML script that pass the XML3 and translate in the so-called SPICE3 kit which is a list of C file that is
12:36
your model ready to be compiled by NGspice. One problem in this process is that we don't
12:47
have the dynamic loading so you have to modify a couple of files to inject the model inside NGspice and recompile because everything is static so it's linked inside the executable.
13:09
This is an old style compiling stuff but we didn't modify it for a long time. AMS and this model has some problem for convergence and noise is not implemented
13:32
but we are working on this. So the roadmap for the model include a lot of things but mainly
13:44
the introduction of Visyn6 and Visyncomo Multigate and the integration of NXP SYMkit mainly for PSP models. On the front-end side we have a lot of improvement especially bug fixes
14:06
and fix of memory leak and we support parametric net, netrist and a command which is called dot
14:28
measure which is a post processing tool so you have to write what you want to be computed
14:46
and you can compute for example the propagation delay of standard cells if you do standard cell
15:01
characterization so you just pick the two points you want to measure and extract the delay and if I remember correctly also the derivative of the trans characteristic.
15:23
We have Monte Carlo analysis also and it's based on our random generator.
15:43
Okay TicoSpice said something on TicoSpice and I skipped this. T-CAD. Okay in this case we have two approaches. One is linked to an external T-CAD software by Cogenda which is
16:04
partially under GPL and the other ways use CIDR which is inside ngSpice and we support just these five models so it's 1D and 2D models. We have a new periodic steady-state analysis.
16:33
This way you can simulate RF systems and at this moment we just support our autonomous
16:45
system to extract period and DFT. Non-autonomous systems are ongoing but they are pretty easy. We have to just insert the node but the other part is on the way and it's not supported yet.
17:08
This is an example. The solution is not very good but you can see the period of this OC and the frequency plot. Okay some slide on Veriloguet. I'm building a new Veriloguet
17:30
compiler from scratch mainly for my PhD and mainly because I don't know anything about Flex Bison and so on so I wanted to learn. So pretty much I'm starting from scratch and you
17:45
want to use C or C++ as main language. Flex and Bison is useful tool for Flex and partial and T-GOL as user interface. I have also semantic analyzer. So this part will be the
18:06
front end and then you have to include the T-GOL script which will be provided with NGspice to extract the model in C. So it's not really different from ADMS but I don't
18:28
use XML and I want to support every construct of Veriloguet. So I don't want to simplify anything. So at the moment I create the preprocessor. The preprocessor is working.
18:44
Just go faster if you have some question I will ask them. And then I have the main parser which is ongoing. It reads the output of preprocessor step. This is an example. So
19:12
you have the console here. Mouse. I have the console here. So when you reach the console,
19:24
the parser has already parsed the model and created the structure. So you can query objects and attributes of the model. For example, this is very basic stuff. You query
19:46
the disciplines and for example, you want to retrieve all the name of the disciplines. In this other example, you want to extract, for example, the name of the modules. You
20:05
have just one modules. And then the name of the part of the module is in comma multigate. This follow, let's say, the synopsis way of things. So it should be similar to,
20:26
I don't know if similar to Hspice, but for sure we design compiler and IC compiler methodology. Just a quick overview on acceleration. We have multi-core, a massive parallelization
20:44
and KLU inside the NGspice. So openMP implementation achieve pretty much 2x,
21:00
but this depends on the circuit and then you just stay on 2x because there is a problem, I think, in the reduction code. So we should fix this, but I didn't work on this part. So this is the plot just to show the speedup. Then I started KLU inside the NGspice and we
21:38
benchmarking suite. So if you look at the biggest one is 13x. Then I created Kuspice,
21:54
which is NGspice for CUDA. It's just a concept. So it doesn't support everything,
22:05
it just supports the minimal models. But if you want to extend this pretty easy, it's just long. So it's long to extend to every model. So I just created this basic stuff
22:26
and I skip this. If you want details, we can discuss how it works. There is a new algorithm here to create the matrix and the right hand side so you don't have the reduction tree
22:42
to sum the contribution in the matrix, but you just apply matrix vector multiplication using a topology matrix. You have two topology matrix, one for the circuit max and one for the right hand side. And the speedup is 9x with the same benchmark suite. So if you use KLU
23:09
and this one, you gain almost 100x, more than 100x. So in conclusion for this part,
23:20
we have roughly 2x for RobinMP, 13x for KLU, and 9x for CUDA. We want to improve this, for example, we didn't approach the changing of the model code, so we just simulate every device in the order. But if you reorder the computation, you can avoid some thread divergence
23:50
inside CUDA. And then we want to extend to the matrix solver, the parallelization technique, but this is really tough and the speedup depends on circuit. So in conclusion, SPICE is here
24:09
since 42 years and is used for both academic and industrial simulation. And NGSPICE is on
24:28
SourceForge, you can freely download it. It supports Gita's versioning system, so you can create branch, fork, and so on to add the contribution. So please visit the
24:48
site. Yes, DMS, I understand correctly. You said AADMS tool has this licensing problem.
25:49
So the question is if all the script are free, right? Okay. So NGSPICE is under BSD license,
26:03
so the original SPICE3 license, so no GPL problems. You can download and integrate in commercial tool, for example. You have to just maintain the name of the author. So from NGSPICE point of view, there is no kind of licensing issue, just this small thing. So
26:28
for example, if you want to download the CUSPICE and integrate in a commercial tool, you have to maintain the initial copyright, which is from NVIDIA, because I developed this
26:41
at NVIDIA, so they release for free, but you have to maintain the statement. Okay. Oh, okay. So the question is why I choose CUDA and not OBE-NCL. Okay. So
27:14
basically because I learned CUDA, so I don't know OBE-NCL very well, but at NVIDIA they use
27:26
mainly their compilers, so their CUDA, and I just used that one because I was there. So it's just this one, not anything else. So the question is if there is some collaboration
28:02
between NGSPICE and CUAX, I have to say we are working on it because we discussed the way to enhance ADMS or maybe use my compiler for the first part and then ADMS for the second part,
28:23
we have to say see what happens because ADMS is not complete, so it supports just a subset of AMS. It doesn't support all the construct that maybe you want to have in the model,
28:42
because from my point of view, let's say the main thing is to avoid to rewrite the model. The model has to be written by the model developer, just to grab the model and do whatever you have to do. So we are working on this. Okay.