LIBPAT(3)
okay bestie, sit down, hydrate, and let me tell you about LIBPAT(3) from the cao-vlsi reference manual β because this one's a whole little universe of data structures and I'm lowkey obsessed π
π ORIGIN π
So this software belongs to the ALLIANCE CAD SYSTEM, developed by the ASIM team at the LIP6 laboratory of UniversitΓ© Pierre et Marie CURIE, in Paris, France. Iconic behavior, no notes π₯β¨
- Web:
http://asim.lip6.fr/recherche/alliance/ - E-mail:
alliance-users@asim.lip6.fr
β¨ NAME β¨
PAT β Generic pattern data structure. Short name, main character energy, periodt π
π DESCRIPTION π
PAT is a generic data structure supporting vlsi concepts, and honestly? It ate. What it does is let you represent a sequence of simulation patterns inside one single data structure.
The goal of PAT β the whole reason it exists β is to define an ad hoc single data structure (an object) where every concept you're juggling in pattern description has a well known, fixed meaning. The dream: any tool that needs to access simulation patterns can just be built on top of it, using these structures. Build once, slay forever π
For each object (data structure), there's a whole set of functions defined so you can add it, delete it, or access it. Those live in the low-level library libPat106.a. Some other functions are higher level β those are chilling in the high-level library libPhl106.a. And then there are the parsers-drivers π¦
- A parser reads a pattern description file in a given format and builds up a complete
PATdata base. - A driver creates a text file in a given format from a
PATdata base.
A pat format parser-driver is available in the libPpt106.a library. Yes, they really did give us the whole pipeline, we're so lucky π
Pattern description involves the following notions (for further details see pat(5)):
- input β port controlled by the user
- output β signal or port observed by the user
- initialization β forcing the value of a register
- pattern sequence β list of values to be forced on inputs, or to be checked as the result of the simulation on outputs
The input-output list is represented by two data structures: pagrp contains informations relative to actual or virtual arraies, and paiol represents a one-bit input-output. Both are simply chained lists. But β and this is the little glow-up β to make more efficient access to paiol structures, they are organized in a table. So a paiol can also be addressed using an offset. Efficient AND cute π
Another group of data structures is used to represent a pattern:
painicontains values to be forced into registers before processing the pattern.paevt gives you an event (a modification of value) on an input-output.papatgathers all information concerning a pattern β including initializations (paini) and events (paevt).
A pacom is used to represent a comment. π
And finally, all these structures can be accessed through a unique structure, paseq, designed to represent a complete sequence of simulation patterns. One structure to rule them all, we stan a hierarchy πΈ
π§ ORGANIZATION π§
Heads up bestie: to use PAT, you actually need to know a thing or two about how libraries work. And since these libraries are under development, the code is subject to change. (Not me warning you in advance, that's growth π)
Here's the deal so you can actually get to work: a static version of each library is always present for the user. Libraries and header files are suffixed by a number β that's the library's version. The programmer can prefer to work with an earlier version of a library rather than the most recent one. However, it is recommended to adapt softwares to libraries as soon as possible, so you can spotlight potential compatibility problems before old libraries are removed. Read that again, it's important β
A makefile is necessary for all PAT applications. Required. Non-negotiable. Why? Because any soft must be easily recompilable, and knowing which libraries a PAT based program actually needs is not an easy matter. It can't be achieved by an other way, so do use makefile. Like, just do it π«Ά
In terms of software organization, PAT is splitted into two libraries for the basic functions, a header file for structures and variable declarations and, up to now, one parser-driver library for pat format.
It is to be noticed that a library's version number is incremented when at least one function composing the library has been modified. Therefore, PAT libraries may evolve independently from each other. They're not a package deal, they're individuals π¦
Here follows the list of the libraries and their contents:
libPat106.a:pat_addpaseq,pat_addpagrp,pat_addpaiol,pat_addpapat,pat_addpaevt,pat_addpaini,pat_addpacom,pat_frepaini,pat_frepaiol,pat_frepacom,pat_frepapat,pat_frepaevt,pat_crtpaiollibPhl106.a:pat_debug,pat_getcountlibPpt106.a:pat_lodpaseq,pat_savpaseq,pat_drvpat,pat_prspat
The libraries are organized in such a way that no cycle can appear through calls π Meaning: if in a given library a function calls another function in another library, then none of the functions of this one does call any function that belongs to the first library. No loops, no drama, no circular friend group.
π₯ EXAMPLE π₯
In order to use PAT libraries, one needs something like this in its makefile:
HEADER = -I/labo/include
LIB = -L/labo/lib -lPat106 -lPhl106 -lPpt106 -lMut315
Look at that. Copy it. Paste it. Thrive π
π SEE ALSO π
mbk(1)pat(5)
Go read them, bestie, iykyk π
π BUG REPORT π
This tool is under development at the ASIM department of the LIP6 laboratory. We need your feedback to improve documentation and tools. Like, genuinely β your girl cannot fix what she doesn't know about ππ«Ά
ngl, this whole page is dated β ASIM/LIP6, October 1, 1997 β and it's from the cao-vlsi reference manual. Old but iconic. Stay hydrated and link with -lMut315 π
β¨
π¦ where this page comes from
- nixos 26.05: alliance 5.1.1-unstable-2025-02-24
- nixpkgs unstable: alliance 5.1.1-unstable-2025-02-24
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms