Register forum user name Search FAQ

Gammon Forum

Notice: Any messages purporting to come from this site telling you that your password has expired, or that you need to "verify" your details, making threats, or asking for money, are spam. We do not email users with any such messages. If you have lost your password you can obtain a new one by using the password reset link.
 Entire forum ➜ SMAUG ➜ SMAUG coding ➜ Too many bits?

Too many bits?

It is now over 60 days since the last post. This thread is closed.     Refresh page


Posted by Zeno   USA  (2,871 posts)  Bio
Date Sun 30 Jan 2005 10:46 PM (UTC)

Amended on Sun 30 Jan 2005 10:47 PM (UTC) by Zeno

Message
Is it possible to have too many (extended BV) bits (for example, too many ACT bits) at all, where it causes problems? If so, I'll probably split up the ACT bits into CONFIG bits and remaining ACT bits.

Zeno McDohl,
Owner of Bleached InuYasha Galaxy
http://www.biyg.org
Top

Posted by Nick Cash   USA  (626 posts)  Bio
Date Reply #1 on Mon 31 Jan 2005 01:50 AM (UTC)
Message
Extended bit's can hold a lot. From my thinking, though it may be wrong, you have 128 bits (32 bits per int * 4 ints), so that should be plenty. If you have more then that I would seperate it into two fields. Again, I may be wrong in my thinking, as no one has confirmed this for me either.

~Nick Cash
http://www.nick-cash.com
Top

Posted by Zeno   USA  (2,871 posts)  Bio
Date Reply #2 on Mon 31 Jan 2005 02:03 AM (UTC)
Message
So basically up to 128 "flags" will be fine? Yeah, I'll be fine if that's right.

Zeno McDohl,
Owner of Bleached InuYasha Galaxy
http://www.biyg.org
Top

Posted by Samson   USA  (683 posts)  Bio
Date Reply #3 on Mon 31 Jan 2005 03:57 AM (UTC)
Message
Yes. EXT_BV holds 128 bits. This is assuming the INTBITS value is defined as 32. As near as I can tell, this should be the case on most systems, it's hard to tell with looking through limits.h in /usr/include. It's even possible that on 64 bit systems INTBITS would be 64, in which case you'd havw 256 flag bits at your disposal.
Top

Posted by Greven   Canada  (835 posts)  Bio
Date Reply #4 on Mon 31 Jan 2005 05:09 AM (UTC)
Message
You can also change the amount of bits in your code by increasing the amount of elements in the int array by increasing XBI. This may have mixed results though, as I have not tested it myself.It may be expecting 5 instead of 4 elements while reading it in from a file, for example.

Nobody ever expects the spanish inquisition!

darkwarriors.net:4848
http://darkwarriors.net
Top

The dates and times for posts above are shown in Universal Co-ordinated Time (UTC).

To show them in your local time you can join the forum, and then set the 'time correction' field in your profile to the number of hours difference between your location and UTC time.


14,048 views.

It is now over 60 days since the last post. This thread is closed.     Refresh page

Go to topic:           Search the forum


[Go to top] top

Information and images on this site are licensed under the Creative Commons Attribution 3.0 Australia License unless stated otherwise.