INNER CODE UNIT · Python

get_shader_stats

Hongtae/SwiftVVD · SupportPackages/SPIRV-Cross/Sources/test_shaders.py:87

def get_shader_stats(shader):
    path = create_temporary()

    p = subprocess.Popen(['malisc', get_shader_type(shader), '--core', 'Mali-T760', '-V', shader], stdout = subprocess.PIPE, stderr = subprocess.PIPE)
    stdout, stderr = p.communicate()
    remove_file(path)

    if p.returncode != 0:
        print(stderr.decode('utf-8'))
        raise OSError('malisc failed')
    p.wait()

    returned = stdout.decode('utf-8')
    return parse_stats(returned)

def print_msl_compiler_version():
    try:
        if platform.system() == 'Darwin':

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…