Sample
Dorn/cuda/11
Human rating uses the original dataset scale.
Scores
| Method | Score | Scale | Dataset rank (0–100) |
|---|---|---|---|
| Posnett | 0 | 0–1; higher is more readable | 54.0Δ 47.1 |
| Scalabrino | 0.561 | 0–1; higher is more readable | 52.3Δ 45.4 |
| Dorn | 0.308 | 0–1; higher is more readable | 24.5Δ 17.5 |
| Mi | 0.38 | 0–1; higher is more readable | 37.0Δ 30.1 |
| LLOC | 3 | Logical lines; fewer is more readable | 88.6Δ 81.6 |
| DeepSeek V4 Pro | 3 | 0–20; mean of three runs | 3.2Δ 3.8 |
| GPT-6.1 Sol | 12.33 | 0–20; mean of three runs | 24.4Δ 17.4 |
| BTTF | 0.225 | 0–1; higher is more readable | 7.5Δ 0.6 |
| Human | 2.24 | 1–5; original rating | 7.0 |
Views
Select the downloaded ZIP or its extracted folder. Files stay in your browser.
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. | 422.644 | −13.947 |
| Byte entropyHow varied the bytes in the source text are. Repeated bytes give a lower value; a more even mixture gives a higher value. | 5.017 | −7.525 |
| Source linesThe number of non-empty source lines. | 10 | +4 |
Intercept 8.87 + feature contributions = -8.603 (log-odds).
Score = sigmoid(-8.603) = 0.
| Score | 0.561 |
|---|
Feature contributions
| Feature | Value | Contribution (log-odds) |
|---|---|---|
| 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. | 119 | −1.375 |
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 119 | +1.116 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.18 | −0.806 |
| Comment layout frequencyHow frequently the layout switches between lines containing only comments or whitespace and lines containing code. | 10 | +0.682 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 8 | −0.46 |
| Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom. | 9.85 | −0.272 |
| Number layout frequencyHow rapidly the number of numeric values per line changes through the code. | 8 | +0.237 |
Intercept 0.07 + feature contributions = -0.809 (log-odds).
Score = sigmoid(-0.809) = 0.308.
| Score | 0.38 |
|---|
| Score | 3 |
|---|
Run 1
The code is largely unreadable due to cryptic macros, commented-out alternatives without explanation, inconsistent naming conventions, and lack of context. The macros SH and SVW abstract array indexing but hide row/column order, with contradictory commented versions adding confusion. Variable names like SH, SVW, W, H, V, WH lack semantic clarity. The kernel signature has no documentation, and the shared memory declarations rely on macro side effects. While the code is short and flat, the dense symbolic notation, unclear intent, and absence of comments or structure make it hard to follow. It fails most readability criteria: structure is tangled, intent is ambiguous, names are opaque, and flow is disrupted by unexplained macro switches.
Run 2
The code is extremely low-level and cryptic due to macro-heavy abstractions. The two macros SH and SVW obscure array indexing, with commented-out alternate row/column-major versions adding confusion about which layout is active. There is no meaningful naming or documentation explaining the kernel's purpose, argument semantics, or the shared memory layout. The kernel signature is dense with multiple pointer arguments and dimensions without explanation. Nesting is minimal, but only because the snippet is too short to have any structure. Action granularity is fine, but intent is unclear. The code assumes deep CUDA and domain knowledge, and the macro usage makes it prone to silent misuse. Overall, readability is poor: concise in length but nearly opaque in meaning.
Run 3
The code is extremely difficult to read due to multiple factors. The macros SH and SVW obscure the underlying array access, and the presence of commented-out alternative definitions adds confusion about which indexing scheme is active. The actual kernel signature and body are minimal, but the heavy reliance on macros destroys clarity of intent. There is no meaningful structure, and the code does not demonstrate clear action granularity or natural reading flow. The naming is cryptic, and the conditional macro definitions make it harder to understand data layout. Overall, this snippet reads like a fragment of a larger, poorly documented system.
Run 1
Code Structure: Macros precede the kernel and shared-memory declarations, giving the fragment a logical organization, but the missing closing brace makes it incomplete. Nesting: Flat, with no deeply nested logic. Clarity of intent: Shared-memory allocation is recognizable, but abbreviated names, an unexplained transposed SH macro, and commented-out alternatives obscure purpose. Code length: Concise, though obsolete alternatives add clutter and the kernel signature is long. Action granularity: Each active macro or declaration occupies its own line. Reading flow: Generally straightforward, but macro expansion hides the actual array indexing and dimensions, requiring readers to mentally translate declarations. The fragment lacks enough implementation to assess the full kernel's readability.
Run 2
Code Structure: The macros and shared-memory declarations are logically grouped, but the kernel is incomplete, limiting assessment. Nesting: The visible code is flat and easy to scan. Clarity of intent: CUDA-style declarations suggest a matrix-processing kernel, but abbreviated names, undocumented dimensions, and macros that reverse indices obscure intent. Code length: The snippet is concise, though commented-out alternative macros add clutter. Action granularity: Each macro or declaration occupies its own line; the long function signature is somewhat dense. Reading flow: Definitions precede their use naturally, but inconsistent index ordering between SH and SVW requires extra attention.
Run 3
Code Structure: The snippet logically places indexing macros before the kernel and shared-memory declarations, but the kernel is incomplete. Nesting: Minimal nesting makes the visible code easy to scan. Clarity of intent: CUDA qualifiers convey a GPU kernel using shared memory, but abbreviated names, undocumented dimensions, and transposed macro indexing obscure its purpose. Code length: The snippet is concise, though commented-out alternative macros add clutter. Action granularity: Each macro or declaration occupies its own line, with no bundled actions. Reading flow: The top-to-bottom flow is straightforward, but the long parameter list and macros used for both indexing and array declarations require extra interpretation.