Repository Analysis

triton-lang/triton

Development repository for the Triton language and compiler

10.3 Low AI signal View on GitHub

Analysis Overview

This report presents the forensic synthetic code analysis of triton-lang/triton, a MLIR project with 19,676 GitHub stars. SynthScan v2.0 examined 384,926 lines of code across 1247 source files, recording 3438 pattern matches distributed across 24 syntactic categories. The overall adjusted score of 10.3 places this repository in the Low AI signal band.

The scanner applied 160+ deterministic lexical heuristics, multi-line block detectors, abstract syntax tree depth profilers, and a cross-file Jaccard similarity matrix to construct a statistically normalised synthetic code estimate. All matches are individually weighted by severity coefficient and contextual multiplier before summation, and the resulting headline score is temporally discounted to account for the repository's development history relative to the commercial emergence of large language model coding tooling (November 2022 onward).

10.3
Adjusted Score
10.3
Raw Score
100%
Time Factor
2026-07-14
Last Push
19.7K
Stars
MLIR
Language
384.9K
Lines of Code
1.2K
Files
3.4K
Pattern Hits
2026-07-14
Scan Date
0.02
HC Hit Rate

What These Metrics Mean

Adjusted Score
Primary synthetic code indicator. Raw score normalised per 1,000 lines of code and multiplied by the temporal discount factor. This is the definitive comparative metric — use it to rank repositories by AI authorship density.
Raw Score
The unmodified sum of all severity-weighted, context-multiplied pattern match scores before temporal discounting. Reflects the absolute signal strength independent of when the repository was last active.
Time Factor
The temporal discount multiplier (0–100%) applied to the raw score. Repositories last updated before ChatGPT's launch (Nov 2022) receive a 5% factor. Full signal is only assigned to repositories active in the post-adoption era (Jan 2024+).
Pattern Hits
Total count of individual pattern matches across all files and categories. A high hit count with a low score may indicate a very large codebase with isolated AI snippets; a low count with a high score indicates dense, concentrated AI signatures.
HC Hit Rate
High+Critical pattern hits per file, averaged across the repository. This orthogonal signal catches repositories where a few files are densely packed with high-severity AI tells — a strong indicator even when the normalised score appears moderate due to codebase size.
Lines of Code / Files
Total lines and files analysed. The scanner examines 94 file extensions. These denominators are used to normalise the score, enabling fair comparison between repositories of vastly different sizes.

Score History

This chart maps the temporal evolution of the adjusted synthetic code score across successive scan runs. An upward trajectory indicates ongoing incorporation of AI-generated code or expanding LLM-assisted scaffolding; a stable or declining trajectory may reflect active human refactoring, code removal, or the adoption of stricter authorship policies. The dashed secondary line (right axis) independently tracks total raw pattern hit count, which can diverge from the normalised score when codebase size changes significantly between scans.

Severity Breakdown

Classifies detected patterns by their diagnostic confidence and structural impact. CRITICAL patterns (coefficient 10) represent definitive synthetic signatures — hallucinated imports, explicit LLM attribution metadata — virtually never produced by human authors. HIGH (5) indicates strong structural tells such as cross-file repetition or cross-linguistic idioms. MEDIUM (2) covers recognisable conversational padding and AI-specific vocabulary. LOW (1) captures subtle indicators like tautological comments and generic boilerplate that require density to carry independent signal.

CRITICAL 15HIGH 7MEDIUM 409LOW 3007

Directory Score Breakdown

This horizontal bar chart decomposes the repository's raw synthetic code score by top-level directory, allowing you to pinpoint precisely which modules or components carry the highest AI authorship density. Directories with disproportionately high scores relative to their size warrant targeted manual review: concentrated AI signatures often trace back to mass-generated configuration layers, auto-ported test suites, LLM-scaffolded boilerplate classes, or entire subsystems authored under heavy copilot assistance. Use this view to prioritise your human code-review effort.

Pattern Findings

The scanner identified 3438 distinct pattern matches across 24 syntactic categories. Each entry below represents a discrete location in the source code where the engine recorded a statistically significant AI authorship indicator. Expand any category row to inspect the individual file paths, line numbers, code snippets, and the lexical context (CODE, COMMENT, or STRING) in which each match was detected.

Reading the findings table: The Severity column indicates the diagnostic confidence level (CRITICAL / HIGH / MEDIUM / LOW). The Context column identifies whether the match occurred inside executable code, an inline comment, or a string literal — comment-context matches receive a ×1.5 weight because LLMs systematically over-annotate. The ⚡ bolt icon marks clustered matches: three or more patterns within a 10-line window, each receiving an additional ×1.5 density multiplier as dense clusters constitute far stronger evidence of synthetic authorship than isolated hits.

Hyper-Verbose Identifiers1205 hits · 1012 pts
SeverityFileLineSnippetContext
LOWsetup.py550def get_triton_version_suffix():CODE
LOWpython/build_helpers.py126def _download_file_with_urllib(url: str, path: str, label: str):CODE
LOWpython/build_helpers.py380def _get_thirdparty_package_cmake_vars(package: Package, helper_args: BuildHelperArgs):CODE
LOWpython/build_helpers.py414def get_thirdparty_cmake_vars(packages: list[str], helper_args: BuildHelperArgs):CODE
LOWpython/build_helpers.py434def write_thirdparty_cmake_vars(output: str, packages: list[str], helper_args: BuildHelperArgs):CODE
LOWpython/build_helpers.py482def download_and_copy_dependencies(helper_args: BuildHelperArgs):CODE
LOWpython/test/conftest.py45def fresh_knobs_including_libraries():CODE
LOWpython/test/unit/test_utils.py18def test_validate_block_shape_rejects_zero():CODE
LOWpython/test/unit/test_utils.py27def test_validate_block_shape_accepts_powers_of_two():CODE
LOWpython/test/unit/test_debug.py24def _run_device_assert_barrier(device):CODE
LOWpython/test/unit/test_debug.py38def _run_expect_zero_device_assert(device):CODE
LOWpython/test/unit/test_debug.py54def test_expect_zero_device_assert(device):CODE
LOWpython/test/unit/test_debug.py76def test_device_assert_barrier(device):CODE
LOWpython/test/unit/test_debug.py151def test_sanitize_int_add_overflow(x, y, x_dtype, y_dtype, debug, should_overflow, device):CODE
LOWpython/test/unit/test_debug.py167def test_sanitize_int_mul_overflow(x, y, x_dtype, y_dtype, debug, should_overflow, device):CODE
LOWpython/test/unit/test_debug.py182def test_sanitize_int_sub_overflow(x, y, x_dtype, y_dtype, debug, should_overflow, device):CODE
LOWpython/test/unit/test_perf_warning.py12def enable_diagnostics_context(value):CODE
LOWpython/test/unit/test_perf_warning.py98def test_remark_vectorization(capfd, fresh_triton_cache):CODE
LOWpython/test/unit/test_perf_warning.py162def test_remark_swp_op_before_operands(capfd, fresh_triton_cache):CODE
LOWpython/test/unit/tools/test_aot.py321def compile_aot_kernel_no_specialization(dir, kernel_path, dtype, BM, BN, BK, target=None):STRING
LOWpython/test/unit/tools/test_aot.py366def generate_matmul_test_data(dir, M, N, K):STRING
LOWpython/test/unit/tools/test_aot.py392def test_compile_link_matmul_no_specialization():STRING
LOWpython/test/unit/tools/test_aot.py459def test_launcher_has_no_available_kernel():STRING
LOWpython/test/unit/tools/test_aot.py497def test_compile_link_autotune_matmul():STRING
LOWpython/test/unit/tools/test_linear_layout.py36def test_operator_mul_identity():CODE
LOWpython/test/unit/tools/test_linear_layout.py42def test_operator_mul_disjoint_dims():CODE
LOWpython/test/unit/tools/test_linear_layout.py75def test_get_matrix_view_identity():CODE
LOWpython/test/unit/tools/test_linear_layout.py83def test_get_matrix_view_strided():CODE
LOWpython/test/unit/tools/test_linear_layout.py92def test_get_matrix_view_from_bases():CODE
LOWpython/test/unit/tools/test_slice_kernel.py45def test_slice_kernel_basic_module_slicing(tmp_path):CODE
LOWpython/test/unit/tools/test_slice_kernel.py733def test_slice_kernel_treats_assign_targets_as_locals(tmp_path):STRING
LOWpython/test/unit/tools/test_slice_kernel.py121def test_slice_kernel_does_not_treat_site_packages_as_stdlib(tmp_path, monkeypatch):STRING
LOWpython/test/unit/tools/test_slice_kernel.py167def test_slice_kernel_does_not_treat_base_python_site_packages_as_stdlib_in_venv(tmp_path, monkeypatch):STRING
LOWpython/test/unit/tools/test_slice_kernel.py215def test_slice_kernel_supports_injected_decorator_matchers(tmp_path):STRING
LOWpython/test/unit/tools/test_slice_kernel.py311def test_slice_kernel_translate_to_gluon_keeps_tensor_method_rewrites(tmp_path):STRING
LOWpython/test/unit/tools/test_slice_kernel.py357def test_slice_kernel_translate_to_gluon_inlines_descriptor_adapter(tmp_path):STRING
LOWpython/test/unit/tools/test_slice_kernel.py404def test_slice_kernel_binds_local_imports(tmp_path):STRING
LOWpython/test/unit/tools/test_slice_kernel.py434def test_slice_kernel_function_import(tmp_path):STRING
LOWpython/test/unit/tools/test_slice_kernel.py469def test_slice_kernel_function_import_module_value(tmp_path):STRING
LOWpython/test/unit/tools/test_slice_kernel.py500def test_slice_kernel_function_relative_import(tmp_path):STRING
LOWpython/test/unit/tools/test_slice_kernel.py542def test_slice_kernel_module_level_imported_value_alias(tmp_path):STRING
LOWpython/test/unit/tools/test_slice_kernel.py575def test_slice_kernel_function_from_import_value(tmp_path):STRING
LOWpython/test/unit/tools/test_slice_kernel.py606def test_slice_kernel_function_absolute_import(tmp_path):STRING
LOWpython/test/unit/tools/test_slice_kernel.py652def test_slice_kernel_function_module_relative_import(tmp_path):STRING
LOWpython/test/unit/tools/test_slice_kernel.py694def test_slice_kernel_function_module_relative_import_leaf(tmp_path):STRING
LOWpython/test/unit/tools/test_slice_kernel.py758def test_slice_kernel_treats_annassign_targets_as_locals(tmp_path):STRING
LOWpython/test/unit/tools/test_slice_kernel.py782def test_slice_kernel_treats_assign_and_annassign_targets_as_locals(tmp_path):STRING
LOWpython/test/unit/tools/test_slice_kernel.py820def test_slice_kernel_translate_to_gluon_avoids_double_descriptor_wrap(tmp_path):STRING
LOWpython/test/unit/tools/test_slice_kernel.py852def test_translate_to_gluon_explicit_expand_dims_rewrites_layout(tmp_path):STRING
LOWpython/test/unit/tools/test_slice_kernel.py886def test_translate_to_gluon_member_fn_expand_dims_rewrites_layout(tmp_path):STRING
LOWpython/test/unit/tools/test_slice_kernel.py920def test_slice_kernel_public_imports():STRING
LOWpython/test/unit/tools/test_irsource.py10def test_mlir_attribute_parsing(tmp_path: pathlib.Path) -> None:CODE
LOWpython/test/unit/tools/test_disasm.py25def test_extract_handles_large_instruction_offsets(monkeypatch):CODE
LOWpython/test/unit/tools/test_triton_to_gluon.py100def test_triton_to_gluon_dot_minimal(tmp_path):CODE
LOWpython/test/unit/tools/test_triton_to_gluon.py222def test_triton_to_gluon_dot_scaled(CODE
LOWpython/test/unit/tools/test_triton_to_gluon.py272def dot_transposed_operand_tile_kernel(CODE
LOWpython/test/unit/tools/test_triton_to_gluon.py308def test_triton_to_gluon_dot_transposed_operands(lhs_transposed, rhs_transposed, tmp_path):CODE
LOWpython/test/unit/tools/test_triton_to_gluon.py435def _skip_unless_descriptor_target():CODE
LOWpython/test/unit/tools/test_triton_to_gluon.py442def test_triton_to_gluon_descriptor_roundtrip(tmp_path):CODE
LOWpython/test/unit/tools/test_triton_to_gluon.py466def test_triton_to_gluon_descriptor_load_roundtrip(tmp_path):CODE
1145 more matches not shown…
Decorative Section Separators368 hits · 966 pts
SeverityFileLineSnippetContext
MEDIUMpython/test/unit/cuda/test_libdevice_cuda.py13# -----------------------COMMENT
MEDIUMpython/test/unit/cuda/test_libdevice_cuda.py15# -----------------------COMMENT
MEDIUMpython/test/unit/language/test_standard.py8# ---------------COMMENT
MEDIUMpython/test/unit/language/test_standard.py10# ---------------COMMENT
MEDIUMpython/test/unit/language/test_standard.py23# ---------------COMMENT
MEDIUMpython/test/unit/language/test_standard.py25# ---------------COMMENT
MEDIUMpython/test/unit/language/test_standard.py62# ---------------COMMENT
MEDIUMpython/test/unit/language/test_standard.py64# ---------------COMMENT
MEDIUMpython/test/unit/language/test_core.py370# ---------------COMMENT
MEDIUMpython/test/unit/language/test_core.py372# ---------------COMMENT
MEDIUMpython/test/unit/language/test_core.py516# ---------------COMMENT
MEDIUMpython/test/unit/language/test_core.py580# ---------------COMMENT
MEDIUMpython/test/unit/language/test_core.py582# ---------------COMMENT
MEDIUMpython/test/unit/language/test_core.py607# ---------------COMMENT
MEDIUMpython/test/unit/language/test_core.py609# ---------------COMMENT
MEDIUMpython/test/unit/language/test_core.py639# ----------COMMENT
MEDIUMpython/test/unit/language/test_core.py641# ----------COMMENT
MEDIUMpython/test/unit/language/test_core.py688# ------------------COMMENT
MEDIUMpython/test/unit/language/test_core.py690# ------------------COMMENT
MEDIUMpython/test/unit/language/test_core.py705# ----------------COMMENT
MEDIUMpython/test/unit/language/test_core.py707# ----------------COMMENT
MEDIUMpython/test/unit/language/test_core.py816# ----------------------------COMMENT
MEDIUMpython/test/unit/language/test_core.py818# ----------------------------COMMENT
MEDIUMpython/test/unit/language/test_core.py832# ---------------COMMENT
MEDIUMpython/test/unit/language/test_core.py834# ---------------COMMENT
MEDIUMpython/test/unit/language/test_core.py926# ---------------COMMENT
MEDIUMpython/test/unit/language/test_core.py928# ---------------COMMENT
MEDIUMpython/test/unit/language/test_core.py959# ----------------COMMENT
MEDIUMpython/test/unit/language/test_core.py961# ----------------COMMENT
MEDIUMpython/test/unit/language/test_core.py1030# -------------COMMENT
MEDIUMpython/test/unit/language/test_core.py1032# -------------COMMENT
MEDIUMpython/test/unit/language/test_core.py1091# ----------------COMMENT
MEDIUMpython/test/unit/language/test_core.py1093# ----------------COMMENT
MEDIUMpython/test/unit/language/test_core.py1138# ----------------COMMENT
MEDIUMpython/test/unit/language/test_core.py1140# ----------------COMMENT
MEDIUMpython/test/unit/language/test_core.py1172# ----------------COMMENT
MEDIUMpython/test/unit/language/test_core.py1174# ----------------COMMENT
MEDIUMpython/test/unit/language/test_core.py1199# ----------------COMMENT
MEDIUMpython/test/unit/language/test_core.py1201# ----------------COMMENT
MEDIUMpython/test/unit/language/test_core.py1382# ---------------COMMENT
MEDIUMpython/test/unit/language/test_core.py1384# ---------------COMMENT
MEDIUMpython/test/unit/language/test_core.py2019# ---------------COMMENT
MEDIUMpython/test/unit/language/test_core.py2021# ---------------COMMENT
MEDIUMpython/test/unit/language/test_core.py2465# ---------------COMMENT
MEDIUMpython/test/unit/language/test_core.py2467# ---------------COMMENT
MEDIUMpython/test/unit/language/test_core.py3079# ---------------COMMENT
MEDIUMpython/test/unit/language/test_core.py3081# ---------------COMMENT
MEDIUMpython/test/unit/language/test_core.py3129# ------------------------COMMENT
MEDIUMpython/test/unit/language/test_core.py3131# ------------------------COMMENT
MEDIUMpython/test/unit/language/test_core.py3326# ---------------COMMENT
MEDIUMpython/test/unit/language/test_core.py3328# ---------------COMMENT
MEDIUMpython/test/unit/language/test_core.py3443# ---------------COMMENT
MEDIUMpython/test/unit/language/test_core.py3445# ---------------COMMENT
MEDIUMpython/test/unit/language/test_core.py4829# ---------------STRING
MEDIUMpython/test/unit/language/test_core.py4831# ---------------STRING
MEDIUMpython/test/unit/language/test_core.py5006# --------------------STRING
MEDIUMpython/test/unit/language/test_core.py5008# --------------------STRING
MEDIUMpython/test/unit/language/test_core.py5278# -------------STRING
MEDIUMpython/test/unit/language/test_core.py5280# -------------STRING
MEDIUMpython/test/unit/language/test_core.py4525# ---------------STRING
308 more matches not shown…
Over-Commented Block867 hits · 832 pts
SeverityFileLineSnippetContext
LOWunittest/Dialect/TritonGPU/SwizzleTest.cpp1#include "triton/Dialect/Triton/IR/Dialect.h"COMMENT
LOWunittest/Dialect/TritonGPU/SwizzleTest.cpp241 int maskedLaneIdx;COMMENT
LOWunittest/Dialect/TritonGPU/SwizzleTest.cpp261 } else {COMMENT
LOW…test/Dialect/TritonGPU/LinearLayoutConversionsTest.cpp3581 {{0, 1}, {0, 2}, {0, 4}, {16, 0}, {32, 0}, {64, 0}, {128, 0}}},COMMENT
LOW…test/Dialect/TritonGPU/LinearLayoutConversionsTest.cpp3601// created after TMA load or used for conceptual access patterns, not forCOMMENT
LOWbin/triton-llvm-opt.cpp1/// Trimmed down clone of llvm opt to be able to test triton custom llvm irCOMMENT
LOWbin/triton-tensor-layout.cpp1#include "RegisterTritonDialects.h"COMMENT
LOWbin/triton-tensor-layout.cpp21//COMMENT
LOWbin/RegisterTritonDialects.h1#pragma onceCOMMENT
LOWbin/RegisterTritonDialects.h21#include "TritonAMDGPUTransforms/Passes.h"COMMENT
LOWpython/test/unit/cuda/test_tma_store_gemm.py1# Copyright (c) 2023 NVIDIA Corporation & Affiliates. All rights reserved.COMMENT
LOWpython/test/unit/language/test_line_info.py301 # CHECK: %offsets_1 = arith.addi %offsets_0, %offsets : tensor<16xi32> loc(#loc16)COMMENT
LOWpython/test/unit/language/test_line_info.py521 # CHECK: #loc = loc("{{.*}}":@DEF_LINE@:5)COMMENT
LOWpython/test/unit/language/test_line_info.py541 # CHECK: } loc(#loc)COMMENT
LOWpython/test/gluon/test_frontend.py221@gluon.jitCOMMENT
LOWpython/test/gluon/test_frontend.py521 # CHECK-NEXT: [[OUTS:%.*]]:3 = ttg.warp_specialize([[A]], [[B]], [[C]], [[A]], [[B]], [[C]]) {{.*}}requestedRegisCOMMENT
LOWpython/test/gluon/test_frontend.py581 # CHECK-DAG: [[BLOCKED_NW4:#.*]] = #ttg.blocked<{sizePerThread = [1], threadsPerWarp = [32], warpsPerCTA = [4], ordeCOMMENT
LOWpython/triton/knobs.py561 #COMMENT
LOWpython/triton/experimental/gsan/src/GSan.h1#pragma onceCOMMENT
LOW…on/experimental/gluon/language/amd/gfx1250/_layouts.py181 # WMMA CTA layout: Below, M runs vertically (rows) and NCOMMENT
LOW…on/experimental/gluon/language/amd/gfx1250/_layouts.py201 # For example, if the block 64x128, the block would look like this:COMMENT
LOWpython/triton/tools/disasm.py1# MIT LicenseCOMMENT
LOW…triton/tools/triton_to_gluon_translator/ordered_set.py1"""COMMENT
LOWpython/examples/gluon/02-conv-dgrad.py61#COMMENT
LOWpython/examples/gluon/02-conv-fprop.py61COMMENT
LOWpython/examples/gluon/02-conv-fprop.py481 output = torch.empty((N, out_h, out_w, Co), device=input_tensor.device, dtype=TORCH_GEMM_DTYPE)COMMENT
LOWpython/examples/gluon/02-conv-wgrad.py61# grad_W[Co, R*S*Ci] = grad_out[M, Co]^T @ im2col(input)[M, R*S*Ci]COMMENT
LOWpython/triton_kernels/tests/test_reduce.py201# bench_reduce(B=16384, M=4, N=8192, dim=1, dtype=torch.float16, mask_mode="broadcast_n")COMMENT
LOWpython/triton_kernels/triton_kernels/matmul.py61 out_handles: torch.TensorCOMMENT
LOW…_kernels/tensor_details/layout_details/hopper_value.py141 # 3: threads[0]COMMENT
LOW…riton_kernels/tensor_details/layout_details/strided.py1from dataclasses import dataclassCOMMENT
LOW…n_kernels/tensor_details/layout_details/torch_utils.py1import torchCOMMENT
LOW…n_kernels/tensor_details/layout_details/torch_utils.py21# if not is_fp4:COMMENT
LOWpython/tutorials/02-fused-softmax.py61COMMENT
LOWpython/tutorials/02-fused-softmax.py181COMMENT
LOWpython/tutorials/08-grouped-gemm.py1"""COMMENT
LOWpython/tutorials/04-low-memory-dropout.py21# The *dropout* operator was first introduced in [SRIVASTAVA2014]_ as a way to improve the performanceCOMMENT
LOWpython/tutorials/04-low-memory-dropout.py81output = dropout(x, x_keep=x_keep, p=p)COMMENT
LOWpython/tutorials/04-low-memory-dropout.py161COMMENT
LOWpython/tutorials/03-matrix-multiplication.py21# -----------COMMENT
LOWpython/tutorials/03-matrix-multiplication.py41# for k in range(0, K, BLOCK_SIZE_K):COMMENT
LOWpython/tutorials/03-matrix-multiplication.py61# For a row-major 2D tensor :code:`X`, the memory location of :code:`X[i, j]` is givenCOMMENT
LOWpython/tutorials/03-matrix-multiplication.py81# offs_k = tl.arange(0, BLOCK_SIZE_K)COMMENT
LOWpython/tutorials/03-matrix-multiplication.py101#COMMENT
LOWpython/tutorials/03-matrix-multiplication.py121# # Number of programs ids along the N axisCOMMENT
LOWpython/tutorials/03-matrix-multiplication.py281 # We will advance this pointer as we move in the K directionCOMMENT
LOWpython/tutorials/05-layer-norm.py21# It takes a vector :math:`x` as input and produces a vector :math:`y` of the same shape as output.COMMENT
LOWpython/tutorials/05-layer-norm.py101#COMMENT
LOWpython/tutorials/10-block-scaled-matmul.py21 python 10-block-scaled-matmul.py --format mxfp8 --K_range 8192 16384 --K_step 2048 --benchCOMMENT
LOWpython/tutorials/10-block-scaled-matmul.py41# where scale_a and scale_b are the blocked scale factors for the A and B matrices.COMMENT
LOWpython/tutorials/10-block-scaled-matmul.py61# In order to conform with Triton's language semantics for dot_scaled, the scale factorsCOMMENT
LOWpython/tutorials/10-block-scaled-matmul.py81#COMMENT
LOWpython/tutorials/10-block-scaled-matmul.py101#COMMENT
LOWpython/tutorials/gluon/05-wgmma.py41# Let's illustrate WGMMA with a trivial kernel launched with grid size (1, ).COMMENT
LOWpython/tutorials/gluon/05-wgmma.py61#COMMENT
LOWpython/tutorials/gluon/05-wgmma.py81#COMMENT
LOWpython/tutorials/gluon/05-wgmma.py101#COMMENT
LOWpython/tutorials/gluon/05-wgmma.py181 # and all this does is immediately wait for 0 outstanding operations. InCOMMENT
LOWpython/tutorials/gluon/05-wgmma.py261# False 32 8.48COMMENT
LOWpython/tutorials/gluon/05-wgmma.py421# We should try to pick the largest `n` for the WGMMA layout. Based on theCOMMENT
807 more matches not shown…
Unused Imports507 hits · 394 pts
SeverityFileLineSnippetContext
LOWpython/test/unit/runtime/test_build.py1CODE
LOWpython/test/unit/language/test_annotations.py1CODE
LOWpython/test/gsan/test_allocator.py1CODE
LOWpython/test/gsan/test_gsan_failures.py1CODE
LOWpython/test/gsan/test_symmetric_memory.py1CODE
LOWpython/test/gsan/test_gsan.py1CODE
LOWpython/triton/knobs.py1CODE
LOWpython/triton/__init__.py8CODE
LOWpython/triton/__init__.py8CODE
LOWpython/triton/__init__.py8CODE
LOWpython/triton/__init__.py8CODE
LOWpython/triton/__init__.py8CODE
LOWpython/triton/__init__.py8CODE
LOWpython/triton/__init__.py8CODE
LOWpython/triton/__init__.py8CODE
LOWpython/triton/__init__.py8CODE
LOWpython/triton/__init__.py8CODE
LOWpython/triton/__init__.py20CODE
LOWpython/triton/__init__.py21CODE
LOWpython/triton/__init__.py21CODE
LOWpython/triton/__init__.py22CODE
LOWpython/triton/__init__.py22CODE
LOWpython/triton/__init__.py23CODE
LOWpython/triton/__init__.py24CODE
LOWpython/triton/__init__.py27CODE
LOWpython/triton/__init__.py28CODE
LOWpython/triton/_utils.py1CODE
LOWpython/triton/experimental/gsan/__init__.py1CODE
LOWpython/triton/experimental/gsan/__init__.py1CODE
LOWpython/triton/experimental/gsan/__init__.py1CODE
LOWpython/triton/experimental/gsan/__init__.py1CODE
LOWpython/triton/experimental/gsan/__init__.py1CODE
LOWpython/triton/experimental/gsan/__init__.py2CODE
LOWpython/triton/experimental/gsan/_testing_utils.py1CODE
LOWpython/triton/experimental/gsan/_allocator.py1CODE
LOWpython/triton/experimental/gsan/symmetric_memory.py1CODE
LOWpython/triton/experimental/gsan/_testing.py1CODE
LOWpython/triton/experimental/gsan/_stream_sync.py1CODE
LOWpython/triton/experimental/gsan/_utils.py1CODE
LOWpython/triton/experimental/gluon/__init__.py1CODE
LOWpython/triton/experimental/gluon/__init__.py1CODE
LOWpython/triton/experimental/gluon/__init__.py1CODE
LOWpython/triton/experimental/gluon/__init__.py2CODE
LOWpython/triton/experimental/gluon/__init__.py2CODE
LOWpython/triton/experimental/gluon/__init__.py3CODE
LOWpython/triton/experimental/gluon/__init__.py4CODE
LOWpython/triton/experimental/gluon/_runtime.py1CODE
LOWpython/triton/experimental/gluon/_runtime.py4CODE
LOWpython/triton/experimental/gluon/language/__init__.py1CODE
LOWpython/triton/experimental/gluon/language/__init__.py1CODE
LOWpython/triton/experimental/gluon/language/__init__.py1CODE
LOWpython/triton/experimental/gluon/language/__init__.py1CODE
LOWpython/triton/experimental/gluon/language/__init__.py1CODE
LOWpython/triton/experimental/gluon/language/__init__.py1CODE
LOWpython/triton/experimental/gluon/language/__init__.py1CODE
LOWpython/triton/experimental/gluon/language/__init__.py1CODE
LOWpython/triton/experimental/gluon/language/__init__.py1CODE
LOWpython/triton/experimental/gluon/language/__init__.py1CODE
LOWpython/triton/experimental/gluon/language/__init__.py1CODE
LOWpython/triton/experimental/gluon/language/__init__.py1CODE
447 more matches not shown…
Hallucination Indicators15 hits · 145 pts
SeverityFileLineSnippetContext
CRITICALpython/test/unit/language/test_core.py4225 if not is_interpreter() and triton.runtime.driver.active.utils.get_device_properties(CODE
CRITICALpython/test/unit/language/test_matmul.py129 shared_mem_avail = triton.runtime.driver.active.utils.get_device_properties(0)["max_shared_mem"]CODE
CRITICALpython/test/gluon/test_frontend.py786 %0 = tt.call @triton.experimental.gluon.language.nvidia.ampere.mbarrier.allocate_mbarrier__cNone_cTrue() : () -> !ttCODE
CRITICALpython/test/gluon/test_frontend.py791 tt.func private @triton.experimental.gluon.language.nvidia.ampere.mbarrier.allocate_mbarrier__cNone_cTrue() -> !ttg.meCODE
CRITICALpython/test/gluon/test_frontend.py3551 %13 = tt.call @triton.experimental.gluon.language._standard.zeros__Tc1T_cfp16_cAL() : () -> tensor<1xf16, #gluon.autCODE
CRITICALpython/test/gluon/test_frontend.py3579 tt.func private @triton.experimental.gluon.language._standard.zeros__Tc1T_cfp16_cAL() -> tensor<1xf16, #gluon.auto_encCODE
CRITICALpython/test/gluon/test_frontend.py3610 %1 = tt.call @triton.experimental.gluon.language._standard.zeros__Tc1T_cbf16_cAL() : () -> tensor<1xbf16, #gluon.autCODE
CRITICALpython/test/gluon/test_frontend.py3628 tt.func private @triton.experimental.gluon.language._standard.zeros__Tc1T_cbf16_cAL() -> tensor<1xbf16, #gluon.auto_enCODE
CRITICALpython/triton/language/core.py3531 triton.runtime.driver.active.utils.set_printf_fifo_size(size_bytes)STRING
CRITICALthird_party/proton/proton/hooks/instrumentation.py157 max_shared_mem = triton.runtime.driver.active.utils.get_device_properties(device)["max_shared_mem"]CODE
CRITICALthird_party/proton/proton/hooks/instrumentation.py182 arch = triton.runtime.driver.active.utils.get_device_properties(device)["arch"].split(":")[0]CODE
CRITICALthird_party/amd/backend/driver.py242 return triton.runtime.driver.active.utils.build_signature_metadata(kernel_signature)CODE
CRITICALthird_party/nvidia/backend/driver.py182 return triton.runtime.driver.active.utils.build_signature_metadata(kernel_signature)CODE
CRITICALthird_party/nvidia/backend/driver.py238 cu_tensor_map = triton.runtime.driver.active.utils.fill_tma_descriptor_im2col(CODE
CRITICALthird_party/nvidia/backend/driver.py253 cu_tensor_map = triton.runtime.driver.active.utils.fill_tma_descriptor_tiled(CODE
Deep Nesting153 hits · 128 pts
SeverityFileLineSnippetContext
LOWsetup.py129CODE
LOWpython/build_helpers.py313CODE
LOWpython/test/unit/tools/test_triton_to_gluon.py520CODE
LOWpython/test/unit/cuda/test_libdevice_cuda.py60CODE
LOWpython/test/unit/runtime/test_specialize.py41CODE
LOWpython/test/unit/language/test_conversions.py15CODE
LOWpython/test/unit/language/test_conversions.py277CODE
LOWpython/test/unit/language/test_core.py383CODE
LOWpython/test/unit/language/test_core.py2765CODE
LOWpython/test/unit/language/test_core.py2943CODE
LOWpython/test/unit/language/test_core.py3448CODE
LOWpython/test/unit/language/test_core.py3628CODE
LOWpython/test/unit/language/test_core.py4440CODE
LOWpython/test/unit/language/test_core.py4665CODE
LOWpython/test/unit/language/test_core.py4836CODE
LOWpython/test/unit/language/test_core.py5288CODE
LOWpython/test/unit/language/test_core.py5761CODE
LOWpython/test/unit/language/test_core.py2769CODE
LOWpython/test/unit/language/test_core.py5291CODE
LOWpython/test/unit/language/test_core.py5764CODE
LOWpython/test/unit/language/test_pipeliner.py215CODE
LOWpython/test/unit/language/test_subprocess.py37CODE
LOWpython/test/unit/language/test_matmul.py526CODE
LOWpython/test/unit/language/test_matmul.py665CODE
LOWpython/test/unit/language/test_matmul.py721CODE
LOWpython/test/unit/language/test_line_info.py164CODE
LOWpython/test/unit/language/test_line_info.py212CODE
LOWpython/test/unit/language/test_annotations.py62CODE
LOWpython/test/unit/language/print_helper.py107CODE
LOWpython/test/unit/language/test_tensor_descriptor.py1555CODE
LOWpython/test/unit/language/test_tensor_descriptor.py1564CODE
LOWpython/test/gsan/test_gsan_failures.py107CODE
LOWpython/test/gsan/test_symmetric_memory.py474CODE
LOWpython/test/gsan/test_gsan.py600CODE
LOWpython/test/gluon/test_lowerings.py15CODE
LOWpython/test/gluon/test_lowerings.py845CODE
LOWpython/test/gluon/test_frontend.py4305CODE
LOWpython/test/gluon/test_frontend.py4308CODE
LOWpython/test/gluon/test_core.py1193CODE
LOWpython/test/gluon/test_core.py2325CODE
LOWpython/test/gluon/test_core.py3202CODE
LOWpython/test/gluon/test_core.py3460CODE
LOWpython/test/gluon/test_core.py3572CODE
LOWpython/test/gluon/test_core.py1273CODE
LOWpython/test/gluon/test_core.py2332CODE
LOWpython/test/gluon/test_consan.py1048CODE
LOWpython/test/gluon/test_consan.py2964CODE
LOWpython/test/gluon/test_consan.py1076CODE
LOWpython/test/gluon/test_consan.py2975CODE
LOWpython/test/gluon/test_fpsan.py540CODE
LOWpython/test/gluon/test_fpsan.py900CODE
LOWpython/test/gluon/test_fpsan.py954CODE
LOWpython/test/gluon/test_fpsan.py1168CODE
LOWpython/test/regression/test_functional_regressions.py137CODE
LOWpython/test/regression/test_functional_regressions.py140CODE
LOWpython/triton/knobs.py297CODE
LOWpython/triton/testing.py45CODE
LOWpython/triton/testing.py119CODE
LOWpython/triton/testing.py189CODE
LOWpython/triton/testing.py340CODE
93 more matches not shown…
Structural Annotation Overuse43 hits · 85 pts
SeverityFileLineSnippetContext
LOWREADME.md261# Step 1: Run the kernel once to dump kernel's IRs and ptx/amdgcn in $TRITON_DUMP_DIRCOMMENT
LOWREADME.md262# Step 2: Copy $TRITON_DUMP_DIR/<kernel_hash> to $TRITON_OVERRIDE_DIRCOMMENT
LOWREADME.md263# Step 3: Delete the stages that you do not want to override and modify the stage you do want to overrideCOMMENT
LOWREADME.md264# Step 4: Run the kernel again to see the overridden resultCOMMENT
LOWpython/tutorials/gluon/13-conv-im2col.py149# Step 1: Extract patches for each output positionCOMMENT
LOWpython/tutorials/gluon/13-conv-im2col.py156# Step 2: Stack patches into im2col matrix A (M=4, K=4)COMMENT
LOWpython/tutorials/gluon/13-conv-im2col.py167# Step 3: Reshape filter into weight matrix W (Co=1, K=4)COMMENT
LOWpython/tutorials/gluon/13-conv-im2col.py171# Step 4: Output = A @ W^TCOMMENT
LOW…ude/triton/Conversion/TritonGPUToLLVM/TargetInfoBase.h92 // NOTE: This function is used for backend debug. DO NOT DELETE.COMMENT
LOWthird_party/amd/lib/TritonAMDGPUToLLVM/TargetInfo.cpp478 // Step 1: Right shift for 8 lanes.COMMENT
LOWthird_party/amd/lib/TritonAMDGPUToLLVM/TargetInfo.cpp481 // Step 2: Right shift for 4 lanes.COMMENT
LOWthird_party/amd/lib/TritonAMDGPUToLLVM/TargetInfo.cpp484 // Step 3: Right shift for 2 lanes.COMMENT
LOWthird_party/amd/lib/TritonAMDGPUToLLVM/TargetInfo.cpp487 // Step 4: Right shift for 1 lane.COMMENT
LOWthird_party/amd/lib/TritonAMDGPUToLLVM/TargetInfo.cpp490 // Step 5: Broadcast lane 15 of each row to all the lanes of its next row.COMMENT
LOWthird_party/amd/lib/TritonAMDGPUToLLVM/TargetInfo.cpp493 // Step 6: Broadcast lane 31 to lane 32-63.COMMENT
LOWthird_party/amd/lib/TritonAMDGPUToLLVM/TargetInfo.cpp498 // Step 7: Read the reduction result from lane 63 and broadcast withCOMMENT
LOWthird_party/amd/lib/TritonAMDGPUToLLVM/Utility.cpp1035 // Step 1: extract EM bits for elements 0,2,4,6 and 1,3,5,7 respectively.COMMENT
LOWthird_party/amd/lib/TritonAMDGPUToLLVM/Utility.cpp1042 // Step 2: convert fp4 to fp8 using LUTCOMMENT
LOWthird_party/amd/lib/TritonAMDGPUToLLVM/Utility.cpp1052 // Step 3: extract sign bitsCOMMENT
LOWthird_party/amd/lib/TritonAMDGPUToLLVM/Utility.cpp1056 // Step 4: assemble 4 packed fp8 values w/ signCOMMENT
LOWthird_party/amd/lib/TritonAMDGPUToLLVM/Utility.cpp1060 // Step 5: convert fp8 to fp32COMMENT
LOWthird_party/amd/lib/TritonAMDGPUToLLVM/Utility.cpp1142 // Step 1: extract EM bits for elements 0,2,4,6 and 1,3,5,7 respectively.COMMENT
LOWthird_party/amd/lib/TritonAMDGPUToLLVM/Utility.cpp1150 // Step 2: extract S bit for elements 0,2,4,6 and 1,3,5,7COMMENT
LOWthird_party/amd/lib/TritonAMDGPUToLLVM/Utility.cpp1158 // Step 3: Upcast elements 0,2,4,6 to 4 16-bit elementsCOMMENT
LOWthird_party/amd/lib/TritonAMDGPUToLLVM/Utility.cpp1187 // Step 4: Upcast elements 1,3,5,7 to 4 16-bit elementsCOMMENT
LOWthird_party/amd/lib/TritonAMDGPUToLLVM/Utility.cpp1217 // Step 5: Reorder 16-bit elements to be 0,1,2,3,4,5,6,7COMMENT
LOW…_party/amd/lib/TritonAMDGPUToLLVM/DotOpToLLVM/MFMA.cpp500 // Step 1: construct each kBase-element vector byCOMMENT
LOW…_party/amd/lib/TritonAMDGPUToLLVM/DotOpToLLVM/MFMA.cpp512 // Step 2: process rawElems based on element typeCOMMENT
LOW…_party/amd/lib/TritonAMDGPUToLLVM/DotOpToLLVM/MFMA.cpp532 // Step 3: Insert the processed vals into the ValueTableCOMMENT
LOW…/lib/Transforms/WarpSpecialization/WSCodePartition.cpp1229 // Step 1: collect all communications between producers and consumers.COMMENT
LOW…/lib/Transforms/WarpSpecialization/WSCodePartition.cpp1240 // Step 2: group channelsCOMMENT
LOW…/lib/Transforms/WarpSpecialization/WSCodePartition.cpp1249 // Step 3: reorder producer ops and the backward slices of the producer ops.COMMENT
LOW…/lib/Transforms/WarpSpecialization/WSCodePartition.cpp1252 // Step 4: find top-level ops that contain a channel, also create new ForOpsCOMMENT
LOW…/lib/Transforms/WarpSpecialization/WSCodePartition.cpp1272 // Step 5: Create buffers. An array of buffers for each channel.COMMENT
LOW…/lib/Transforms/WarpSpecialization/WSCodePartition.cpp1280 // Step 6: Lower the loads. Also add local copy ops for non-loadCOMMENT
LOW…/lib/Transforms/WarpSpecialization/WSCodePartition.cpp1290 // Step 7: Create tokens. A set of tokens for each group of channels forCOMMENT
LOW…/lib/Transforms/WarpSpecialization/WSCodePartition.cpp1301 // Step 8: add async communication ops (ProducerAcquire etc). Also lowerCOMMENT
LOW…/hopper/lib/Transforms/WarpSpecialization/WSBuffer.cpp304 // Step 1: Append accumCnts as forOp arguments.COMMENT
LOW…/hopper/lib/Transforms/WarpSpecialization/WSBuffer.cpp308 // Step 2: Add accumCnts to yieldOp.COMMENT
LOW…/hopper/lib/Transforms/WarpSpecialization/WSBuffer.cpp317 // Step 3: Create loop arguments for the new ForOp.COMMENT
LOW…/hopper/lib/Transforms/WarpSpecialization/WSBuffer.cpp326 // Step 4: Create newForOp and take the region of the original forOp.COMMENT
LOW…/hopper/lib/Transforms/WarpSpecialization/WSBuffer.cpp332 // Step 5: Replace forOp with newForOp.COMMENT
LOWlib/Dialect/TritonGPU/IR/LinearLayoutConversions.cpp1151 // Step 3: Along the "register" dim, remove any all-zero bases.COMMENT
Verbosity Indicators41 hits · 79 pts
SeverityFileLineSnippetContext
LOWpython/triton/runtime/jit.py202 # The purpose of this function is to visit everything in `arguments`COMMENT
LOWpython/tutorials/gluon/13-conv-im2col.py149# Step 1: Extract patches for each output positionCOMMENT
LOWpython/tutorials/gluon/13-conv-im2col.py156# Step 2: Stack patches into im2col matrix A (M=4, K=4)COMMENT
LOWpython/tutorials/gluon/13-conv-im2col.py167# Step 3: Reshape filter into weight matrix W (Co=1, K=4)COMMENT
LOWpython/tutorials/gluon/13-conv-im2col.py171# Step 4: Output = A @ W^TCOMMENT
LOWthird_party/amd/lib/TritonAMDGPUToLLVM/TargetInfo.cpp478 // Step 1: Right shift for 8 lanes.COMMENT
LOWthird_party/amd/lib/TritonAMDGPUToLLVM/TargetInfo.cpp481 // Step 2: Right shift for 4 lanes.COMMENT
LOWthird_party/amd/lib/TritonAMDGPUToLLVM/TargetInfo.cpp484 // Step 3: Right shift for 2 lanes.COMMENT
LOWthird_party/amd/lib/TritonAMDGPUToLLVM/TargetInfo.cpp487 // Step 4: Right shift for 1 lane.COMMENT
LOWthird_party/amd/lib/TritonAMDGPUToLLVM/TargetInfo.cpp490 // Step 5: Broadcast lane 15 of each row to all the lanes of its next row.COMMENT
LOWthird_party/amd/lib/TritonAMDGPUToLLVM/TargetInfo.cpp493 // Step 6: Broadcast lane 31 to lane 32-63.COMMENT
LOWthird_party/amd/lib/TritonAMDGPUToLLVM/TargetInfo.cpp498 // Step 7: Read the reduction result from lane 63 and broadcast withCOMMENT
LOWthird_party/amd/lib/TritonAMDGPUToLLVM/Utility.cpp1035 // Step 1: extract EM bits for elements 0,2,4,6 and 1,3,5,7 respectively.COMMENT
LOWthird_party/amd/lib/TritonAMDGPUToLLVM/Utility.cpp1042 // Step 2: convert fp4 to fp8 using LUTCOMMENT
LOWthird_party/amd/lib/TritonAMDGPUToLLVM/Utility.cpp1052 // Step 3: extract sign bitsCOMMENT
LOWthird_party/amd/lib/TritonAMDGPUToLLVM/Utility.cpp1056 // Step 4: assemble 4 packed fp8 values w/ signCOMMENT
LOWthird_party/amd/lib/TritonAMDGPUToLLVM/Utility.cpp1060 // Step 5: convert fp8 to fp32COMMENT
LOWthird_party/amd/lib/TritonAMDGPUToLLVM/Utility.cpp1142 // Step 1: extract EM bits for elements 0,2,4,6 and 1,3,5,7 respectively.COMMENT
LOWthird_party/amd/lib/TritonAMDGPUToLLVM/Utility.cpp1150 // Step 2: extract S bit for elements 0,2,4,6 and 1,3,5,7COMMENT
LOWthird_party/amd/lib/TritonAMDGPUToLLVM/Utility.cpp1158 // Step 3: Upcast elements 0,2,4,6 to 4 16-bit elementsCOMMENT
LOWthird_party/amd/lib/TritonAMDGPUToLLVM/Utility.cpp1187 // Step 4: Upcast elements 1,3,5,7 to 4 16-bit elementsCOMMENT
LOWthird_party/amd/lib/TritonAMDGPUToLLVM/Utility.cpp1217 // Step 5: Reorder 16-bit elements to be 0,1,2,3,4,5,6,7COMMENT
LOW…_party/amd/lib/TritonAMDGPUToLLVM/DotOpToLLVM/MFMA.cpp500 // Step 1: construct each kBase-element vector byCOMMENT
LOW…_party/amd/lib/TritonAMDGPUToLLVM/DotOpToLLVM/MFMA.cpp512 // Step 2: process rawElems based on element typeCOMMENT
LOW…_party/amd/lib/TritonAMDGPUToLLVM/DotOpToLLVM/MFMA.cpp532 // Step 3: Insert the processed vals into the ValueTableCOMMENT
LOW…/lib/Transforms/WarpSpecialization/WSCodePartition.cpp1229 // Step 1: collect all communications between producers and consumers.COMMENT
LOW…/lib/Transforms/WarpSpecialization/WSCodePartition.cpp1240 // Step 2: group channelsCOMMENT
LOW…/lib/Transforms/WarpSpecialization/WSCodePartition.cpp1249 // Step 3: reorder producer ops and the backward slices of the producer ops.COMMENT
LOW…/lib/Transforms/WarpSpecialization/WSCodePartition.cpp1252 // Step 4: find top-level ops that contain a channel, also create new ForOpsCOMMENT
LOW…/lib/Transforms/WarpSpecialization/WSCodePartition.cpp1272 // Step 5: Create buffers. An array of buffers for each channel.COMMENT
LOW…/lib/Transforms/WarpSpecialization/WSCodePartition.cpp1280 // Step 6: Lower the loads. Also add local copy ops for non-loadCOMMENT
LOW…/lib/Transforms/WarpSpecialization/WSCodePartition.cpp1290 // Step 7: Create tokens. A set of tokens for each group of channels forCOMMENT
LOW…/lib/Transforms/WarpSpecialization/WSCodePartition.cpp1301 // Step 8: add async communication ops (ProducerAcquire etc). Also lowerCOMMENT
LOW…/hopper/lib/Transforms/WarpSpecialization/WSBuffer.cpp304 // Step 1: Append accumCnts as forOp arguments.COMMENT
LOW…/hopper/lib/Transforms/WarpSpecialization/WSBuffer.cpp308 // Step 2: Add accumCnts to yieldOp.COMMENT
LOW…/hopper/lib/Transforms/WarpSpecialization/WSBuffer.cpp317 // Step 3: Create loop arguments for the new ForOp.COMMENT
LOW…/hopper/lib/Transforms/WarpSpecialization/WSBuffer.cpp326 // Step 4: Create newForOp and take the region of the original forOp.COMMENT
LOW…/hopper/lib/Transforms/WarpSpecialization/WSBuffer.cpp332 // Step 5: Replace forOp with newForOp.COMMENT
LOWthird_party/nvidia/lib/NVGPUToLLVM/NVGPUToLLVMPass.cpp606 // TODO: pred will have a long liverange, we need to check if this is aCOMMENT
LOWlib/Dialect/TritonGPU/IR/LinearLayoutConversions.cpp1151 // Step 3: Along the "register" dim, remove any all-zero bases.COMMENT
LOW…t/TritonInstrument/Transforms/ConcurrencySanitizer.cpp887 // Op is writing to the buffer, we need to check if anything elseCOMMENT
Modern Structural Boilerplate66 hits · 62 pts
SeverityFileLineSnippetContext
LOWpython/triton/__init__.py33__all__ = [CODE
LOWpython/triton/experimental/gsan/__init__.py4__all__ = [CODE
LOWpython/triton/experimental/gluon/__init__.py6__all__ = ["aggregate", "amd", "constexpr_function", "GluonJITFunction", "jit", "must_use_result", "nvidia"]CODE
LOWpython/triton/experimental/gluon/_runtime.py10__all__ = ["GluonJITFunction", "constexpr_function", "jit"]CODE
LOWpython/triton/experimental/gluon/language/_core.py53__all__ = [CODE
LOWpython/triton/experimental/gluon/language/_core.py301 def _set_name(self, builder: ir.builder, name: str) -> None:STRING
LOWpython/triton/experimental/gluon/language/amd/slice.py8__all__ = ["slice"]CODE
LOW…hon/triton/experimental/gluon/language/amd/__init__.py9__all__ = [CODE
LOW…hon/triton/experimental/gluon/language/amd/_layouts.py9__all__ = [CODE
LOW…on/experimental/gluon/language/amd/cdna4/async_copy.py6__all__ = [CODE
LOW…iton/experimental/gluon/language/amd/cdna4/__init__.py16__all__ = [CODE
LOW…iton/experimental/gluon/language/amd/cdna3/__init__.py13__all__ = [CODE
LOW…iton/experimental/gluon/language/amd/rdna4/__init__.py4__all__ = ["wmma"]CODE
LOW…iton/experimental/gluon/language/amd/rdna3/__init__.py4__all__ = ["wmma"]CODE
LOW…/experimental/gluon/language/amd/gfx1250/async_copy.py6__all__ = ["global_to_shared", "shared_to_global", "commit_group", "wait_group", "mbarrier_arrive"]CODE
LOW…on/experimental/gluon/language/amd/gfx1250/__init__.py14__all__ = [CODE
LOW…/triton/experimental/gluon/language/amd/gfx1250/tdm.py14__all__ = [CODE
LOW…/triton/experimental/gluon/language/amd/gfx1250/tdm.py66 def _set_name(self, builder: ir.builder, name: str) -> None:CODE
LOW…ton/experimental/gluon/language/amd/gfx1250/cluster.py3__all__ = ["arrive", "wait"]CODE
LOW…on/experimental/gluon/language/amd/gfx1250/_layouts.py9__all__ = [CODE
LOW…on/experimental/gluon/language/amd/gfx1250/mbarrier.py5__all__ = ["MBarrierLayout", "init", "wait", "arrive"]CODE
LOW…/triton/experimental/gluon/language/nvidia/__init__.py4__all__ = ["blackwell", "hopper"]CODE
LOW…/experimental/gluon/language/nvidia/hopper/__init__.py11__all__ = [CODE
LOW…/experimental/gluon/language/nvidia/hopper/__init__.py90 def _set_name(self, builder: ir.builder, name: str) -> None:CODE
LOW…n/experimental/gluon/language/nvidia/hopper/cluster.py5__all__ = ["arrive", "wait", "barrier"]CODE
LOW…riton/experimental/gluon/language/nvidia/hopper/tma.py12__all__ = [CODE
LOW…riton/experimental/gluon/language/nvidia/hopper/tma.py121 def _set_name(self, builder: ir.builder, name: str) -> None:CODE
LOW…/experimental/gluon/language/nvidia/hopper/mbarrier.py4__all__ = [CODE
LOW…experimental/gluon/language/nvidia/blackwell/float2.py5__all__ = [CODE
LOW…perimental/gluon/language/nvidia/blackwell/__init__.py21__all__ = [CODE
LOW…perimental/gluon/language/nvidia/blackwell/__init__.py227 def _set_name(self, builder: ir.builder, name: str) -> None:CODE
LOW…on/experimental/gluon/language/nvidia/blackwell/tma.py22__all__ = [CODE
LOW…on/experimental/gluon/language/nvidia/blackwell/clc.py18__all__ = [CODE
LOW…on/experimental/gluon/language/nvidia/blackwell/clc.py86 def _set_name(self, builder: ir.builder, name: str) -> None:CODE
LOW…xperimental/gluon/language/nvidia/ampere/async_copy.py5__all__ = [CODE
LOW…/experimental/gluon/language/nvidia/ampere/__init__.py9__all__ = ["async_copy", "mbarrier", "mma_v2"]CODE
LOW…/experimental/gluon/language/nvidia/ampere/mbarrier.py8__all__ = ["allocate_mbarrier", "arrive", "init", "invalidate", "MBarrierLayout", "wait"]CODE
LOW…n/triton/experimental/gluon/language/extra/__init__.py3__all__ = ["libdevice"]CODE
LOWpython/triton/experimental/gluon/amd/__init__.py3__all__ = ["gfx1250"]CODE
LOWpython/triton/experimental/gluon/amd/gfx1250.py7__all__ = ["TensorDescriptor"]CODE
LOWpython/triton/experimental/gluon/nvidia/blackwell.py3__all__ = ["TensorDescriptor"]CODE
LOWpython/triton/experimental/gluon/nvidia/__init__.py4__all__ = ["hopper", "blackwell"]CODE
LOWpython/triton/experimental/gluon/nvidia/hopper.py7__all__ = ["TensorDescriptor", "TensorDescriptorIm2Col"]CODE
LOW…riton/tools/triton_to_gluon_translator/slice_kernel.py31logger = logging.getLogger(__name__)CODE
LOWpython/triton/runtime/__init__.py7__all__ = [CODE
LOWpython/triton/runtime/interpreter.py907 def set_attr(self, obj: object, name: str, value: object) -> None:CODE
LOWpython/triton/runtime/_allocation.py29def set_allocator(allocator: Allocator) -> None:CODE
LOWpython/triton/runtime/_allocation.py59def set_profile_allocator(allocator: Optional[Allocator]) -> None:CODE
LOWpython/triton/runtime/driver.py42 def set_active(self, driver: DriverBase) -> None:CODE
LOWpython/triton/language/__init__.py144__all__ = [CODE
LOWpython/triton/language/core.py162 def _set_name(self, builder: ir.builder, name: str) -> None:CODE
LOWpython/triton/language/core.py239 def _set_name(self, builder: ir.builder, name: str) -> None:CODE
LOWpython/triton/language/core.py903 def _set_name(self, builder: ir.builder, name: str) -> None:CODE
LOWpython/triton/language/core.py1351 def _set_name(self, builder: ir.builder, name: str) -> None:CODE
LOWpython/triton/language/core.py1418 def _set_name(self, builder: ir.builder, name: str) -> None:CODE
LOWpython/triton/language/core.py1544 def _set_name(self, builder: ir.builder, name: str) -> None:CODE
LOWpython/triton/language/core.py1722 def _set_name(self, builder: ir.builder, name: str) -> None:CODE
LOWpython/triton/language/target_info.py4__all__ = ["current_target"]CODE
LOWpython/triton/compiler/__init__.py4__all__ = [CODE
LOWpython/triton/compiler/code_generator.py444 def set_value(self, name: str, value: Union[base_value, constexpr]) -> None:CODE
6 more matches not shown…
Excessive Try-Catch Wrapping45 hits · 51 pts
SeverityFileLineSnippetContext
LOWsetup.py528 except Exception:CODE
LOWsetup.py536 except Exception:CODE
MEDIUMsetup.py524def get_git_commit_hash(length=8):CODE
MEDIUMsetup.py532def get_git_branch():CODE
LOWpython/test/unit/runtime/test_cache.py883 except Exception as e:STRING
LOWpython/test/unit/language/test_core.py5268 except Exception as e:STRING
LOWpython/test/unit/language/test_decorator.py27 except Exception as e:CODE
LOWpython/test/backend/test_mir_stage.py11 except Exception:CODE
MEDIUMpython/test/backend/test_mir_stage.py8def is_hip():CODE
LOWpython/triton/_internal_testing.py262 except Exception as e:CODE
LOWpython/triton/experimental/gsan/symmetric_memory.py165 except Exception:CODE
LOWpython/triton/experimental/gsan/symmetric_memory.py267 except Exception:CODE
LOWpython/triton/experimental/gsan/symmetric_memory.py454 except Exception:CODE
MEDIUMpython/triton/experimental/gsan/symmetric_memory.py264def __del__(self) -> None:CODE
LOWpython/triton/experimental/gsan/_utils.py113 except Exception:CODE
LOWpython/triton/runtime/cache.py81 except Exception:CODE
LOWpython/triton/runtime/cache.py225 except Exception:CODE
LOWpython/triton/runtime/_async_compile.py22 except Exception:CODE
LOWpython/triton/runtime/interpreter.py1425 except Exception as e:CODE
LOWpython/triton/runtime/interpreter.py1466 except Exception:CODE
LOWpython/triton/runtime/interpreter.py1559 except Exception as e:CODE
LOWpython/triton/runtime/autotuner.py159 except Exception as e:CODE
LOWpython/triton/compiler/compiler.py308 except Exception as e:CODE
LOWpython/triton/compiler/code_generator.py1382 except Exception as e:CODE
LOWpython/triton/compiler/code_generator.py1433 except Exception as e:CODE
LOWpython/triton/compiler/code_generator.py1598 except Exception as e:CODE
LOWpython/triton/compiler/code_generator.py1633 except Exception as e:CODE
LOWpython/examples/gluon/02-conv-dgrad.py980 except Exception:CODE
MEDIUMpython/examples/gluon/02-conv-dgrad.py937def _benchmark_dgrad_config(CODE
LOWpython/examples/gluon/02-conv-wgrad.py735 except Exception:CODE
MEDIUMpython/examples/gluon/02-conv-wgrad.py692def _benchmark_wgrad_config(CODE
LOWthird_party/proton/test/test_instrumentation.py938 except Exception as e:CODE
MEDIUMthird_party/proton/test/test_instrumentation.py935def run_kernel():CODE
LOWthird_party/proton/test/test_api.py98 except Exception as e:CODE
LOWthird_party/proton/test/test_api.py120 except Exception as e:CODE
LOWthird_party/proton/test/test_api.py133 except Exception as e:CODE
LOWthird_party/proton/test/test_api.py287 except Exception as e:CODE
LOWthird_party/proton/test/test_api.py404 except Exception as e:CODE
LOWthird_party/proton/test/test_api.py414 except Exception as e:CODE
LOW…ton/test/reproducers/cupti_graph_replay_heap_growth.py275 except Exception:CODE
LOWthird_party/proton/proton/proton.py46 except Exception as e:STRING
MEDIUMthird_party/proton/proton/proton.py47 print("An error occurred while executing the script:")STRING
LOWthird_party/amd/python/test/test_gluon_gfx1250.py2020 except Exception as e:CODE
LOWthird_party/amd/backend/driver.py45 except Exception:CODE
LOWthird_party/nvidia/backend/driver.py58 except Exception:CODE
Self-Referential Comments17 hits · 49 pts
SeverityFileLineSnippetContext
MEDIUMpython/build_helpers.py356 # Create a stable symlink that doesn't include revisionCOMMENT
MEDIUMpython/test/gluon/test_core.py3028 # Create a test matrix with known valuesCOMMENT
MEDIUMpython/test/gluon/test_core.py3860 # Create a test matrix [N, M]COMMENT
MEDIUMpython/test/gluon/test_core.py4021 # Create a test tensor [N, M, P]COMMENT
MEDIUMpython/triton/experimental/gluon/language/_semantic.py618 # Create the warp specialize op.COMMENT
MEDIUMpython/triton/experimental/gluon/language/_layouts.py617 # Create a idendity mapping based on shape_per_cta + orderCOMMENT
MEDIUMpython/triton/runtime/jit.py404 # Create the function argument list and the dict entries for the return statementCOMMENT
MEDIUMpython/triton/runtime/jit.py1144 # Create a bound function to support constexpr_function methodsSTRING
MEDIUMpython/triton/language/core.py1674 # Define the wrapped Triton value type.COMMENT
MEDIUM…rnels/tensor_details/layout_details/blackwell_scale.py181 # The following code is equivalent to the above, but faster for GPU tensors.COMMENT
MEDIUMpython/tutorials/02-fused-softmax.py173 # Create a number of persistent programs.COMMENT
MEDIUMpython/tutorials/01-vector-add.py46 # Create a mask to guard memory operations against out-of-bounds accesses.COMMENT
MEDIUMdocs/conf.py6# This file is execfile()d with the current directory set to itsCOMMENT
MEDIUMthird_party/proton/proton/hooks/instrumentation.py39 # Create the bufferCOMMENT
MEDIUMthird_party/proton/proton/hooks/instrumentation.py111 # Create the appropriate mode instanceCOMMENT
MEDIUMthird_party/amd/python/test/test_gluon_gfx1250.py2238 # Create a flattened view into the nD reference to unify the indexing logic over all dimensionsCOMMENT
MEDIUM…ird_party/amd/python/examples/gluon/mxfp_fa_gfx1250.py3063 # Create a pytest idCOMMENT
AI Slop Vocabulary15 hits · 40 pts
SeverityFileLineSnippetContext
MEDIUM…riton/tools/triton_to_gluon_translator/slice_kernel.py118 # HACK: An AST rewrite would be more robust, but this works for now.COMMENT
MEDIUMpython/triton/runtime/cache.py115 # use temp dir to be robust against program interruptionsCOMMENT
LOWpython/triton/runtime/interpreter.py1463 # e.g., dynamically generated functions, we cannot rewrite it so just return the original functionCOMMENT
MEDIUMpython/triton_kernels/bench/bench_dense_matmul.py3# This is not meant to be a comprehensive benchmark of triton_kernels.COMMENT
MEDIUMpython/triton_kernels/bench/bench_dense_matmul.py135 # even for the fp16 benchmark path. Match that when reproducing the OpenAI harness.COMMENT
MEDIUMpython/tutorials/09-persistent-matmul.py411 # Enable warp specialization to leverage async warp scheduling in the GPU.COMMENT
MEDIUMpython/tutorials/10-block-scaled-matmul.py390 # With 256 elements we better utilize the L2 and don't require the TMACOMMENT
MEDIUMpython/tutorials/gluon/11-tcgen05-mma-scaled.py654 # elements. With 256 bytes along the inner dimension, we better utilize theCOMMENT
MEDIUMpython/tutorials/gluon/08-warp-specialization.py369# specialization is especially powerful when used to build intricate schedulesCOMMENT
MEDIUMpython/tutorials/gluon/02-layouts.py868# Linear layouts are extremely poweful, and can be used in conjunction withCOMMENT
MEDIUMpython/tutorials/gluon/07-persistence.py841# work in conjunction with the GPU, getting the best of both worlds. This isCOMMENT
LOWthird_party/amd/python/test/test_gluon_gfx1250.py2802 # In practice, since we know that phase is initialized to 0, we can just set count = NUM_WARPS * WARP_SIZE and call COMMENT
LOWthird_party/amd/python/test/test_gluon_gfx1250.py2863 # In practice, since we know that phase is initialized to 0, we can just set count = NUM_WARPS and call directly ttgCOMMENT
MEDIUM…party/amd/lib/TritonAMDGPUTransforms/ScheduleLoops.cpp210/// which is not coalesced. To better utilize global memory bandwidth,COMMENT
MEDIUM…party/amd/lib/TritonAMDGPUToLLVM/LoadStoreOpToLLVM.cpp2261 // In the case of unpaired f16 elements utilize dpp instructions toCOMMENT
AI Structural Patterns39 hits · 36 pts
SeverityFileLineSnippetContext
LOWpython/test/unit/language/test_core.py221CODE
LOWpython/triton/testing.py22CODE
LOWpython/triton/experimental/gluon/_runtime.py75CODE
LOWpython/triton/tools/ragged_tma.py76CODE
LOW…/tools/triton_to_gluon_translator/blackwell_helpers.py93CODE
LOW…/tools/triton_to_gluon_translator/blackwell_helpers.py205CODE
LOW…/tools/triton_to_gluon_translator/blackwell_helpers.py304CODE
LOW…triton/tools/triton_to_gluon_translator/amd_helpers.py302CODE
LOW…ton/tools/triton_to_gluon_translator/nvidia_helpers.py53CODE
LOW…ton/tools/triton_to_gluon_translator/nvidia_helpers.py133CODE
LOW…/triton/tools/triton_to_gluon_translator/translator.py256CODE
LOWpython/triton/runtime/jit.py953CODE
LOWpython/triton/runtime/autotuner.py408CODE
LOWpython/triton/runtime/autotuner.py21CODE
LOWpython/triton/language/standard.py389CODE
LOWpython/triton/language/core.py2497CODE
LOWpython/triton/language/core.py1911CODE
LOWpython/triton/language/core.py3802CODE
LOWpython/triton/compiler/code_generator.py288CODE
LOWpython/examples/gluon/04-2cta-block-scale-matmul.py797CODE
LOWpython/triton_kernels/triton_kernels/matmul.py243CODE
LOWpython/triton_kernels/triton_kernels/matmul.py823CODE
LOWpython/triton_kernels/triton_kernels/reduce.py664CODE
LOWpython/triton_kernels/triton_kernels/reduce.py1143CODE
LOWpython/triton_kernels/triton_kernels/reduce.py1181CODE
LOWpython/triton_kernels/triton_kernels/testing.py238CODE
LOWpython/triton_kernels/triton_kernels/swiglu.py100CODE
LOWpython/triton_kernels/triton_kernels/swiglu.py82CODE
LOW…n_kernels/tensor_details/layout_details/cdna4_scale.py77CODE
LOW…_kernels/tensor_details/layout_details/hopper_value.py224CODE
LOW…_kernels/tensor_details/layout_details/hopper_value.py187CODE
LOW…rnels/tensor_details/layout_details/blackwell_scale.py213CODE
LOW…_kernels/tensor_details/layout_details/hopper_scale.py112CODE
LOW…ton_kernels/triton_kernels/matmul_details/_p_matmul.py62CODE
LOW…riton_kernels/triton_kernels/matmul_details/_matmul.py43CODE
LOWpython/tutorials/02-fused-softmax.py59CODE
LOWpython/tutorials/gluon/14-multicta.py1066CODE
LOWthird_party/amd/python/examples/gluon/moe_gfx1250.py1202CODE
LOW…ird_party/amd/python/examples/gluon/mxfp_fa_gfx1250.py2918CODE
Overly Generic Function Names19 hits · 20 pts
SeverityFileLineSnippetContext
LOWpython/test/unit/tools/test_slice_kernel.py723def helper() -> None:CODE
LOWpython/test/unit/tools/test_slice_kernel.py739 def helper() -> int:CODE
LOWpython/test/unit/tools/test_slice_kernel.py130 def helper() -> int:CODE
LOWpython/test/unit/tools/test_slice_kernel.py157def helper() -> int:CODE
LOWpython/test/unit/tools/test_slice_kernel.py178 def helper() -> int:CODE
LOWpython/test/unit/tools/test_slice_kernel.py205def helper() -> int:CODE
LOWpython/test/unit/tools/test_slice_kernel.py440 def helper() -> None:CODE
LOWpython/test/unit/tools/test_slice_kernel.py455def helper() -> None:CODE
LOWpython/test/unit/tools/test_slice_kernel.py475 def helper():CODE
LOWpython/test/unit/tools/test_slice_kernel.py490def helper():CODE
LOWpython/test/unit/tools/test_slice_kernel.py513 def helper() -> None:CODE
LOWpython/test/unit/tools/test_slice_kernel.py532def helper() -> None:CODE
LOWpython/test/unit/tools/test_slice_kernel.py581 def helper():CODE
LOWpython/test/unit/tools/test_slice_kernel.py596def helper():CODE
LOWpython/test/unit/tools/test_slice_kernel.py623 def helper() -> None:CODE
LOWpython/test/unit/tools/test_slice_kernel.py642def helper() -> None:CODE
LOWpython/test/unit/tools/test_slice_kernel.py665 def helper() -> None:CODE
LOWpython/test/unit/tools/test_slice_kernel.py684def helper() -> None:CODE
LOWpython/test/unit/tools/test_slice_kernel.py707 def helper() -> None:CODE
Cross-File Repetition3 hits · 15 pts
SeverityFileLineSnippetContext
HIGH…iton/experimental/gluon/language/amd/rdna4/__init__.py0computes matrix-multiplication of a * b + acc using amd wmma instruction. args: a (tensor): the operand a to be multipliSTRING
HIGH…iton/experimental/gluon/language/amd/rdna3/__init__.py0computes matrix-multiplication of a * b + acc using amd wmma instruction. args: a (tensor): the operand a to be multipliSTRING
HIGH…on/experimental/gluon/language/amd/gfx1250/__init__.py0computes matrix-multiplication of a * b + acc using amd wmma instruction. args: a (tensor): the operand a to be multipliSTRING
Redundant / Tautological Comments10 hits · 13 pts
SeverityFileLineSnippetContext
LOWpython/build_helpers.py96 # Set timeout to 300 seconds to prevent the request from hanging forever.COMMENT
LOWpython/triton/compiler/code_generator.py143# Check if the given syntax node has an "early" returnCOMMENT
LOWutils/generate-test-checks.py177 # Check if an existing variable exists for this name.STRING
LOWutils/generate-test-checks.py320 # Check if this is an attribute definition and process itSTRING
LOWthird_party/proton/proton/hooks/hook.py93 # Check if any other sessions rely on this hookCOMMENT
LOWthird_party/amd/python/test/address_sanitizer_helper.py23 #Set access to go out of bounds for ASAN testCOMMENT
LOWthird_party/amd/backend/driver.py330 # Check if cooperative groups are supported on the device.COMMENT
LOW.github/workflows/integration-tests-nvidia.yml41 # Check if files exist before proceedingCOMMENT
LOW.github/workflows/integration-tests-amd.yml65 # Check if files exist before proceedingCOMMENT
LOW.github/workflows/build-macos.yml37 # Check if files exist before proceedingCOMMENT
Cross-Language Confusion2 hits · 10 pts
SeverityFileLineSnippetContext
HIGHpython/test/unit/tools/test_aot.py147 while (fscanf(file, "%hd,", &buffer[index]) != EOF && index < size) {CODE
HIGHpython/triton/experimental/gsan/symmetric_memory.py406 stack.push(listener)CODE
Slop Phrases4 hits · 8 pts
SeverityFileLineSnippetContext
LOWpython/test/unit/language/test_core.py6671 # reuse the temp variable and make sure to check that it isn't creating incorrect IR.STRING
LOWpython/tutorials/01-vector-add.py74 # - Don't forget to pass meta-parameters as keywords arguments.COMMENT
MEDIUMpython/tutorials/gluon/14-multicta.py357# It's worth noting that the pattern changes a bit once the TMA has to wait on the tcgen05_mmaCOMMENT
MEDIUMpython/tutorials/gluon/02-layouts.py839# require reordering registers within a thread (which is free), you can useCOMMENT
AI Response Leakage1 hit · 8 pts
SeverityFileLineSnippetContext
HIGHpython/tutorials/11-programmatic-dependent-launch.py26# In this exampleCOMMENT
Fake / Example Data11 hits · 6 pts
SeverityFileLineSnippetContext
LOWpython/test/unit/language/test_line_info.py585 run_filecheck("placeholder", h.asm["ttir"], check_template)STRING
LOWpython/test/unit/language/test_line_info.py344 run_filecheck("placeholder", h.asm["ttir"], check_template)STRING
LOWpython/test/unit/language/test_line_info.py364 run_filecheck("placeholder", h.asm["ttir"], check_template)STRING
LOWpython/test/unit/language/test_line_info.py383 run_filecheck("placeholder", h.asm["ttir"], check_template)STRING
LOWpython/test/unit/language/test_line_info.py396 run_filecheck("placeholder", h.asm["ttir"], check_template)STRING
LOWpython/test/unit/language/test_line_info.py416 run_filecheck("placeholder", h.asm["ttir"], check_template)STRING
LOWpython/test/unit/language/test_line_info.py442 run_filecheck("placeholder", h.asm["ttir"], check_template)STRING
LOWpython/test/unit/language/test_line_info.py466 run_filecheck("placeholder", h.asm["ttir"], check_template)STRING
LOWpython/test/unit/language/test_line_info.py493 run_filecheck("placeholder", h.asm["ttir"], check_template)STRING
LOWpython/test/unit/language/test_line_info.py606 run_filecheck("placeholder", h.asm["ttir"], check_template)STRING
LOWpython/triton/_filecheck.py87 run_filecheck("placeholder", mlir_module.str_nodebug(), check_template)CODE
Docstring Block Structure1 hit · 5 pts
SeverityFileLineSnippetContext
HIGH…/triton/experimental/gluon/language/amd/gfx1250/tdm.py160Update selected fields of a TDM descriptor; return a new descriptor SSA value. Each parameter is independently optiSTRING
TODO Padding3 hits · 4 pts
SeverityFileLineSnippetContext
LOWthird_party/amd/backend/include/hip/hip_runtime_api.h2500// TODO: implement IPC apisCOMMENT
LOWlib/Analysis/Alias.cpp67 // TODO: implementCOMMENT
LOWlib/Analysis/Alias.cpp73 // TODO: implementCOMMENT
Dead Code2 hits · 4 pts
SeverityFileLineSnippetContext
MEDIUMpython/test/unit/language/test_compile_errors.py171CODE
MEDIUMpython/triton_kernels/triton_kernels/tensor.py98CODE
Example Usage Blocks1 hit · 2 pts
SeverityFileLineSnippetContext
LOWbin/triton-tensor-layout.cpp23// Example usage:COMMENT