mirror of
https://github.com/tinygrad/tinygrad.git
synced 2026-01-07 22:23:55 -05:00
* checkout files from autogen branch
* ioctl with payload
* fix am generations
* properly fix generations
This reverts commit b2a54f4f41.
* revert discovery.h
* support pragma pack(1)
* typo
* better getter
* typo
* NVCEC0_QMDV05_00_RELEASE[01]_ENABLE
* align support
* anon handling fix
---------
Co-authored-by: George Hotz <72895+geohot@users.noreply.github.com>
25 lines
689 B
Bash
Executable File
25 lines
689 B
Bash
Executable File
#!/bin/sh
|
|
|
|
if [ "$#" -ne 1 ] || ! [ -d $1 ]; then
|
|
echo "usage: $0 MESA_PREFIX"
|
|
exit 1
|
|
fi
|
|
|
|
TMP=$(mktemp)
|
|
trap 'rm -f "$TMP"' EXIT
|
|
|
|
(
|
|
cat <<EOF
|
|
#define HAVE_ENDIAN_H
|
|
#define HAVE_STRUCT_TIMESPEC
|
|
#define HAVE_PTHREAD
|
|
#include <unistd.h>
|
|
#include "nir_shader_compiler_options.h"
|
|
#include "compiler/shader_enums.h"
|
|
EOF
|
|
sed -n '/struct nir_shader_compiler_options/,/^}/{p;/^}/q}' $1/src/gallium/drivers/llvmpipe/lp_screen.c
|
|
echo "int main(void) { write(1, &gallivm_nir_options, sizeof(gallivm_nir_options)); }"
|
|
) | cc -x c -o $TMP - -I$1/src/compiler/nir -I$1/src -I$1/include || exit 1
|
|
|
|
printf 'lvp_nir_options = gzip.decompress(base64.b64decode("%s"))' $("$TMP" | gzip | base64 -w0)
|