File: inline-asm-dpas.cl

package info (click to toggle)
intel-graphics-compiler2 2.16.0-2
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 106,644 kB
  • sloc: cpp: 805,640; lisp: 287,672; ansic: 16,414; python: 3,952; yacc: 2,588; lex: 1,666; pascal: 313; sh: 186; makefile: 35
file content (27 lines) | stat: -rw-r--r-- 840 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
/*========================== begin_copyright_notice ============================

Copyright (C) 2024 Intel Corporation

SPDX-License-Identifier: MIT

============================= end_copyright_notice ===========================*/

// The test checks if has_dpas property is set correctly in ZEInfo when calling
// dpas instruction in inline assembly.
//


// REQUIRES: regkeys, dg2-supported

// RUN: ocloc compile -file %s -options "-igc_opts 'DumpZEInfoToConsole=1'" \
// RUN:     -device dg2 | FileCheck %s

// CHECK:     has_dpas:        true

void kernel test() {
    __asm__ volatile("{\n"
            ".decl DUMMY_DPAS_SRC v_type=G type=ud num_elts=128\n"
            ".decl DUMMY_DPAS_DST v_type=G type=f num_elts=128\n"
            "dpas.bf.bf.8.1 (M1,8) DUMMY_DPAS_DST.0 V0.0 DUMMY_DPAS_SRC.0 DUMMY_DPAS_SRC(0,0)\n"
   "}\n");
}