Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 10 Jan 2025 19:01:17 +0000
From:      bugzilla-noreply@freebsd.org
To:        bugs@FreeBSD.org
Subject:   [Bug 168213] [kernel] why is the type of ub_cnt signed in uma_int.h?
Message-ID:  <bug-168213-227-Usmr0CXcQv@https.bugs.freebsd.org/bugzilla/>
In-Reply-To: <bug-168213-227@https.bugs.freebsd.org/bugzilla/>

index | next in thread | previous in thread | raw e-mail

https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=168213

Mark Johnston <markj@FreeBSD.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |markj@FreeBSD.org
         Resolution|---                         |Not A Bug
             Status|Open                        |Closed

--- Comment #2 from Mark Johnston <markj@FreeBSD.org> ---
They could be made unsigned, but the maximum values are in practice much
smaller than the limits imposed by the type.  In particular, ub_cnt and
ub_entries are int16_t, but the largest bucket size is 256 (see bucket zones)
and is unlikely to ever grow past 512 in the future.  In this case, it's fairly
ordinary to use signed types.

-- 
You are receiving this mail because:
You are the assignee for the bug.

home | help

Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-168213-227-Usmr0CXcQv>