Files
Frederik Gossen fa79b60282 Fix nightly lint-urls failures on dead and bot-blocked URLs (#189718)
The nightly Link checks / lint-urls job was failing on three URLs that
the 403/429/503 WAF carve-out (added in #188510) does not cover: two
returned 000 (no HTTP response) and one returned 404.

- cmake/Modules/FindMAGMA.cmake: the MAGMA homepage moved from
  http://icl.cs.utk.edu/magma/ (dead, 000) to https://icl.utk.edu/magma/.
- functorch/dim/README.md: pytorch.org/docs/stable/named_tensor.html now
  404s because named tensors and its doc were removed in #173895. Pin the
  reference to docs.pytorch.org/docs/2.8/named_tensor.html, the last
  release that still serves the page.
- torch.compiler_performance_dashboard.md: hud.pytorch.org is live but its
  WAF drops the linter's connection (000), so annotate the line with
  @lint-ignore, matching how bot-protected hosts are handled.

Test Plan:
lintrunner passed on the three changed files. Verified each replacement
URL returns 200 and the originals fail (000/404) via curl with the same
user agent the linter uses. The nightly lint-urls job exercises the
end-to-end check.

Authored with Claude.
Pull Request resolved: https://github.com/pytorch/pytorch/pull/189718
Approved by: https://github.com/zou3519
2026-07-13 22:03:04 +00:00

56 lines
1.7 KiB
CMake

# - Find MAGMA library
# This module finds an installed MAGMA library, a matrix algebra library
# similar to LAPACK for GPU and multicore systems
# (see https://icl.utk.edu/magma/).
#
# This module will look for MAGMA library under /usr/local/magma by
# default. To use a different installed version of the library set
# environment variable MAGMA_HOME before running cmake (e.g.
# MAGMA_HOME=${HOME}/lib/magma instead of default /usr/local/magma)
#
# This module sets the following variables:
# MAGMA_FOUND - set to true if the MAGMA library is found.
# MAGMA_LIBRARIES - list of libraries to link against to use MAGMA
# MAGMA_INCLUDE_DIR - include directory
if(MAGMA_FOUND)
return()
endif()
include(FindPackageHandleStandardArgs)
SET(MAGMA_LIBRARIES)
SET(MAGMA_INCLUDE_DIR)
FIND_LIBRARY(MAGMA_LIBRARIES magma
HINTS $ENV{MAGMA_HOME} /usr/local/magma
PATH_SUFFIXES lib)
FIND_PATH(MAGMA_INCLUDE_DIR magma.h
HINTS $ENV{MAGMA_HOME} /usr/local/magma
PATH_SUFFIXES include)
IF (MAGMA_LIBRARIES)
SET(MAGMA_FOUND TRUE)
ELSE (MAGMA_LIBRARIES)
SET(MAGMA_FOUND FALSE)
ENDIF (MAGMA_LIBRARIES)
add_library(torch::magma INTERFACE IMPORTED)
set_property(TARGET torch::magma
PROPERTY INTERFACE_INCLUDE_DIRECTORIES "${MAGMA_INCLUDE_DIR}")
set_property(TARGET torch::magma
PROPERTY INTERFACE_LINK_LIBRARIES "${MAGMA_LIBRARIES}")
# Check for Magma V2
include(CheckPrototypeDefinition)
check_prototype_definition(magma_get_sgeqrf_nb
"magma_int_t magma_get_sgeqrf_nb( magma_int_t m, magma_int_t n );"
"0"
"magma.h"
MAGMA_V2)
if(MAGMA_V2)
set_property(TARGET torch::magma
PROPERTY INTERFACE_COMPILE_DEFINITIONS "MAGMA_V2")
endif(MAGMA_V2)