User:CompuHacker/CHDS9000

The DeathStation 9000 (often abbreviated DS9K) is a hypothetical computer architecture often used as part of a discussion about the portability of computer code (often C code). It is imagined to be as obstructive and unhelpful as possible, whilst still conforming to any relevant standards, deliberately acting unexpectedly whenever possible. For instance, the strcmp function in C compares strings and indicates the string that comes first alphabetically under most systems; however, this is not guaranteed by the C99 standard, and on a C99-conforming DS9K it would do little more useful than a check whether strings are equal or not (because it sorts strings by character code, and nothing compels a DS9K's character codes to be in alphabetical order, though digits are required to be in order).

A common, more dramatic example concerns undefined behavior, which is allowed to have any effect. With many C compilers, the statement i = i++; where i is an integer variable will either increment i or leave i with the same value when run (the behavior is undefined). On a DS9K, it is possible (even probable) that executing that statement will cause demons to fly out of the user's nose.[1]

The DS9K is a concept that seems to have developed on Usenet, specifically on the groups comp.lang.c and (to a lesser extent) comp.lang.c++ and comp.std.c.

A website about the DS9K was created, probably as an April Fool's Day joke.[2]

DeathStation 9000 or DS9K is sometimes also used as an adjective, as in "a DS9K endianness", meaning an endianness which is neither big-endian nor little-endian, like the American date format MM/DD/YYYY.

Implementations

DS9K: The destroyer of worlds (Open-source, C interpreter/debugger)

References

Content Disclaimer

Informasi ini disarikan dari Wikipedia dan disajikan kembali untuk tujuan edukasi. Konten tersedia di bawah lisensi CC BY-SA 3.0. Kami tidak bertanggung jawab atas ketidakakuratan data yang bersumber dari kontribusi publik tersebut.

  1. The information displayed on this website is sourced in part or in whole from Wikipedia and has been adapted for the purpose of restating it. We strive to provide accurate and relevant information, however:
  2. There is no guarantee of absolute accuracy. Wikipedia is an open, collaborative project that can be edited by anyone, so information is subject to change.
  3. It is not intended to constitute professional advice. The content displayed is for informational and educational purposes only. For important decisions (e.g., medical, legal, or financial), please consult a professional.
  4. Content copyright. Wikipedia is licensed under the Creative Commons Attribution-ShareAlike License (CC BY-SA). This means that content may be reused with appropriate attribution and shared under a similar license.
  5. Responsible use. Any risk arising from the use of information from this website is entirely the responsibility of the user.