-
Notifications
You must be signed in to change notification settings - Fork 85
Open
Labels
essentialWill cause failure to meet customer requirements. Assign resources.Will cause failure to meet customer requirements. Assign resources.
Description
Change d82da0e refactored the shield into its own structure, ShieldStruct, which makes sense in terms of abstractions. Various checks that were part of GlobalCheck were moved to the new ShieldCheck and shield checking was then done in the usual way by a CHECKD . The trouble with this change is that ShieldCheck is never reached in normal builds.
There are several problems:
- CHECKD does not recurse in a cool (debugging) build, because by default that build uses CheckLevelSHALLOW. This means that ArenaCheck does not invoke ShieldCheck.
- Important shield functions such as ShieldEnter take an arena instead of a shield, then check that. But that doesn't invoke ShieldCheck (see above).
- We do not regularly run tests with CheckLevelDEEP which would cause CHECKD to recurse.
With several possible solutions:
- CHECKD might be the wrong thing for a single-instance inlined structure such as ShieldStruct within ArenaStruct.
- Shield functions should take a shield and check it.
- We should build and run a deep checking build on at least one platform.
On this last point, a build with make -f lii6ll.gmk VARIETY=cool CFLAGSDEBUG='-O0 -g3 -DCHECKLEVEL=CheckLevelDEEP' testci currently fails in several tests.
This issue was discovered during a walkthrough of e47bc4c04 with @rptb1 and @thejayps .
A similar problem may apply to HistoryStruct introduced by 811d535 and possibly others.
Metadata
Metadata
Assignees
Labels
essentialWill cause failure to meet customer requirements. Assign resources.Will cause failure to meet customer requirements. Assign resources.