An error return indication was added, as there as no other way to abort
execution but indicate to caller the data was not filled in.
No call sites have been modified to check the error return as the
assertion is still in place and expects to catch this unexpected scenario.
gaStem.c:914:2: warning: variable 'start' is used uninitialized whenever switch default is taken
gaStem.c:914:2: warning: variable 'min' is used uninitialized whenever switch default is taken
gaStem.c:914:2: warning: variable 'max' is used uninitialized whenever switch default is taken
clang18 -Wall warning cleanup [-Wsometimes-uninitialized]
gaStem.c:225:9: warning: suggest parentheses around assignment used as truth value
gaStem.c:350:9: warning: suggest parentheses around assignment used as truth value
grouteMain.c:363:12: warning: suggest parentheses around assignment used as truth value
grouteMaze.c:573:17: warning: suggest parentheses around assignment used as truth value
groutePath.c:127:13: warning: suggest parentheses around assignment used as truth value
irCommand.c:901:12: warning: suggest parentheses around assignment used as truth value
irCommand.c:999:12: warning: suggest parentheses around assignment used as truth value
irCommand.c:1275:13: warning: suggest parentheses around assignment used as truth value
irCommand.c:1375:13: warning: suggest parentheses around assignment used as truth value
irCommand.c:1931:17: warning: suggest parentheses around assignment used as truth value
rtrDcmpose.c:435:12: warning: suggest parentheses around assignment used as truth value
rtrPin.c:174:17: warning: suggest parentheses around assignment used as truth value
rtrStem.c:373:21: warning: suggest parentheses around assignment used as truth value
rtrStem.c:479:9: warning: suggest parentheses around assignment used as truth value
rtrStem.c:952:17: warning: suggest parentheses around assignment used as truth value
gcrInit.c:239:9: warning: suggest parentheses around assignment used as truth value
net2ir.c:123:13: warning: suggest parentheses around assignment used as truth value
GCC14 -Wall cleanup series [-Wparentheses]
request #325 from Daryl Miles. Made a few simple style changes
to conform to (what is vaguely defined as) the overall programming
style for magic (passed down from John Ousterhout).
This resolution assumes that all records and values of ch->gcr_type are expected
to be one of the 3 cases in the switch. The bug it on the first iteration it is
possible 'tot' and 'clear' is just not initializaed and on a subsequent iteration
it is possible it ot setup to the previous interation values.
SonarCloud
garouter/gaChannel.c:385:3rd function call argument is an uninitialized value
https://sonarcloud.io/project/issues?open=AZJB17fFNGfDNup0RkoE&id=dlmiles_magic
Alessandro De Laurenzis. That pull request cleaned up the vast
majority of compiler warnings. However, that cleanup exposed a
few additional warnings pointing to errors in the code that needed
fixing. The code now compiles cleanly except for one warning
about redefined CAD_DIR that I have not looked into.
This commit makes the code (mostly) C99-compatible, enabling to compile
it without the -Wno-error=implicit-function-declaration flag. This
way, Magic becomes usable on arm64 architectures, specifically on Apple
computers with M1/M2 SoC.
one is an "off_grid" DRC type, which can be used to check geometry
that is below the manufacturing grid. Normally magic prevents the
grid from being subdivided below the manufacturing grid, but this
limit can be removed and replaced by DRC checks to check for such
errors in a GDS file of unknown origin. The second version looks
for interactions between subcells that end up with intersections
of non-manhattan geometry landing on points that are not on the
database internal grid. Such errors cannot be seen by magic's DRC
engine by definition, and so must be detected while flattening
geometry for the DRC checks.
to stop the search whenever a cell is not found. Used this to implement
a new option for GDS writes, "gds undefined allow|disallow" (default
"disallow") controls whether or not GDS with undefined references will
be allowed to be written. Similarly affects CIF and LEF writes, extraction,
and DRC (when running "drc check" from the top).