Remove deprecated --structs-packed.

This commit is contained in:
Wilson Snyder
2026-09-13 14:54:34 -04:00
parent e172e94b30
commit 547eb6a836
12 changed files with 9 additions and 97 deletions
-4
View File
@@ -1774,10 +1774,6 @@ void V3Options::parseOptsList(FileLine* fl, const string& optdir, int argc,
DECL_OPTION("-std-package", OnOff, &m_stdPackage);
DECL_OPTION("-std-waiver", OnOff, &m_stdWaiver);
DECL_OPTION("-stop-fail", OnOff, &m_stopFail);
DECL_OPTION("-structs-packed", CbOnOff, [this, fl](bool flag) {
m_structsPacked = flag;
fl->v3warn(DEPRECATED, "Option --structs-packed is deprecated, avoid use");
}).undocumented();
DECL_OPTION("-sv", CbCall, [this]() { m_defaultLanguage = V3LangCode::L1800_2023; });
DECL_OPTION("-no-threads", CbCall, [this, fl]() {
-2
View File
@@ -294,7 +294,6 @@ private:
VOptionBool m_schedZeroDelay; // main switch: --sched-zero-delay
bool m_stdPackage = true; // main switch: --std-package
bool m_stdWaiver = true; // main switch: --std-waiver
bool m_structsPacked = false; // main switch: --structs-packed
bool m_systemC = false; // main switch: --sc: System C instead of simple C++
bool m_stats = false; // main switch: --stats
bool m_statsVars = false; // main switch: --stats-vars
@@ -510,7 +509,6 @@ public:
bool statsVars() const { return m_statsVars; }
bool stdPackage() const { return m_stdPackage; }
bool stdWaiver() const { return m_stdWaiver; }
bool structsPacked() const { return m_structsPacked; }
bool assertOn() const { return m_assert; } // assertOn as __FILE__ may be defined
bool assertCase() const { return m_assertCase; }
bool autoflush() const { return m_autoflush; }
+1 -5
View File
@@ -3827,7 +3827,6 @@ class WidthVisitor final : public VNVisitor {
if (unionp->isTagged()) { nodep->v3warn(E_UNSUPPORTED, "Unsupported: tagged union"); }
}
// UINFOTREE(9, nodep, "", "class-in");
if (!nodep->packed() && v3Global.opt.structsPacked()) nodep->packed(true);
userIterateChildren(nodep, nullptr); // First size all members
nodep->dtypep(nodep);
nodep->isFourstate(false);
@@ -3835,10 +3834,7 @@ class WidthVisitor final : public VNVisitor {
for (AstMemberDType* itemp = nodep->membersp(); itemp;
itemp = VN_AS(itemp->nextp(), MemberDType)) {
AstNodeDType* const dtp = itemp->subDTypep()->skipRefp();
if (nodep->packed()
&& !dtp->isIntegralOrPacked()
// Historically lax:
&& !v3Global.opt.structsPacked())
if (nodep->packed() && !dtp->isIntegralOrPacked())
itemp->v3error("Unpacked data type "
<< dtp->prettyDTypeNameQ()
<< " in packed struct/union (IEEE 1800-2023 7.2.1)");