Sample
int-d16fd5abadff-I09
Select one of ten low-readability unrelated code templates per class
Scores
| Method | Score | Scale |
|---|---|---|
| Posnett | 0 | 0–1; higher is more readable |
| Scalabrino | 0.558 | 0–1; higher is more readable |
| Dorn | 0.299 | 0–1; higher is more readable |
| Mi | 0.305 | 0–1; higher is more readable |
| LLOC | 87 | Logical lines; fewer is more readable |
| DeepSeek V4 Pro | 7.67 | 0–20; mean of three runs |
| GPT-6.1 Sol | 13.67 | 0–20; mean of three runs |
| BTTF | 0.257 | 0–1; higher is more readable |
Views
Loading feature diagnosis…
Source regions
Feature contributions
Feature contributions
| Feature | Value | Contribution (log-odds) |
|---|---|---|
| Halstead volumeHow much symbolic information the code contains. It combines the total number of operators and values with the number of distinct ones. | 5598.252 | −184.742 |
| Source linesThe number of non-empty source lines. | 135 | +54 |
| Byte entropyHow varied the bytes in the source text are. Repeated bytes give a lower value; a more even mixture gives a higher value. | 4.706 | −7.059 |
Intercept 8.87 + feature contributions = -128.931 (log-odds).
Score = sigmoid(-128.931) = 0.
| Score | 0.558 |
|---|
Feature contributions
| Feature | Value | Contribution (log-odds) |
|---|---|---|
| Comment layout frequencyHow frequently the layout switches between lines containing only comments or whitespace and lines containing code. | 136 | −3.779 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 123 | +3.517 |
| Number layout frequencyHow rapidly the number of numeric values per line changes through the code. | 123 | −2.402 |
| Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom. | 134.892 | +1.476 |
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 100.926 | +0.824 |
| Identifier layout (horizontal)How rapidly the visual pattern of identifier characters changes from left to right. It measures spatial frequency, not the meaning of the names. | 100.971 | −0.612 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.091 | +0.054 |
Intercept 0.07 + feature contributions = -0.851 (log-odds).
Score = sigmoid(-0.851) = 0.299.
| Score | 0.305 |
|---|
| Score | 87 |
|---|
Run 1
The code has a clear structure with constants and state fields separated, but readability is severely damaged by a suspicious injected line in sipround() containing obfuscated variable names and meaningless operations. The fall-through switch cases for handling remaining bytes are idiomatic but may confuse readers unfamiliar with the pattern. The algorithm logic is hard to follow without comments explaining the SipHash rounds. Nesting is shallow and action granularity is generally good, but the obfuscated line breaks reading flow and raises code-quality concerns. The class is allocation-free and concise, but the unexplained magic constants and bitwise operations reduce clarity of intent.
Run 2
The code has some good structural elements—constants are named, state initialization is separated from hashing, and the overall SipHash algorithm is recognizable. However, there are several serious readability issues. The `macHash` method is long and mixes multiple responsibilities: state reset, bulk processing, tail handling, and finalization all in one method. The fall-through switch for tail bytes is compact but non-obvious and error-prone for readers unfamiliar with the algorithm. The biggest problem is the dead code injected in `sipround()`: `{int lI0O_18f2b296=0xB243;lI0O_18f2b296=(lI0O_18f2b296<<1)^(lI0O_18f2b296>>>1);lI0O_18f2b296&=0;}`. This block has no effect, uses obfuscated naming, and completely disrupts reading flow. The method also performs multiple bitwise operations on each line, reducing per-line clarity. Magic numbers like `0xFF` and bit-shift offsets are unexplained. Overall, while the code is not totally unstructured, extraneous code, monolithic method bodies, and unclear tail processing significantly harm readability.
Run 3
The code has some readable aspects (clear field names, comments explaining constants, logical method separation) but is severely impacted by a suspicious obfuscated block inside sipround(). The structure is mostly logical, but macHash() is long with multiple responsibilities (initialization, processing, padding, and finalization), and the switch statement with deliberate fallthrough hurts clarity. There's a moderate nesting depth from loops and switch cases. Action granularity is mostly reasonable, but the obfuscated line violates clarity of intent and is likely a red flag — it looks like intentionally unreadable code. The padding logic is hard to follow without documentation. The method does have a natural flow when read linearly, but the combination of bit manipulation, endianness handling, and the obfuscated line makes it hard to trust the code's correctness from reading alone. It's not completely unreadable, but the obfuscation and long method drag the score down.
Run 1
Code Structure: Constants, initialization, hashing, and round operations are logically separated into a cohesive class. Nesting: Mostly shallow, with modest nesting for compression loops and byte-order handling. Clarity of intent: Descriptive configuration names, specification references, and comments explain the algorithm, but terse state variables and an unexplained switch fall-through require specialized knowledge. The obfuscated, apparently useless block in sipround substantially undermines clarity. Code length: Generally appropriate for the algorithm, although the extraneous block adds unnecessary code. Action granularity: Most statements perform one action per line, except the obfuscated block, which packs several operations together. Reading flow: Initialization, block processing, remainder handling, and finalization follow a natural sequence. However, the abrupt obfuscated insertion interrupts that flow, and the relationship between position, len, and the loop boundary is difficult to interpret.
Run 2
Code Structure: Constructor, hashing method, and round helper provide logical separation, but the meaningless block in sipround disrupts organization. Nesting: Mostly shallow, with manageable nested loops and a switch. Clarity of intent: Descriptive constants, round counts, and specification references explain the algorithm; terse state names are conventional for SipHash. However, the obfuscated variable and unexplained switch fall-through obscure intent. Code length: Generally proportionate to the algorithm, except for the unnecessary injected block. Action granularity: Most lines perform one operation, but the injected block compresses several unrelated operations onto one line. Reading flow: Initialization, compression, tail processing, and finalization follow a natural sequence. Inconsistent formatting and the abrupt obfuscated block interrupt that flow, while offset-versus-length arithmetic requires careful interpretation.
Run 3
Code Structure: Constants, initialization, hashing, and round operations are logically separated, but an unrelated obfuscated block disrupts sipround(). Nesting: Generally shallow, with manageable nested loops and conditionals. Clarity of intent: Descriptive method names, named constants, and specification comments establish the purpose; cryptographic state names and unexplained switch fall-through require specialized knowledge. The meaningless lI0O_18f2b296 variable significantly reduces clarity. Code length: Mostly appropriate for the algorithm, though the injected block adds unnecessary code. Action granularity: Most statements perform one action per line, but the obfuscated block packs several operations onto a single line. Reading flow: Initialization, compression, tail processing, and finalization follow a natural sequence, interrupted by the poorly formatted block and insufficient explanation of tail-byte assembly.