blob: 5fb8d412ae5f34bccaca262daeb91e25f4bedbb3 [file] [log] [blame]
Tom Stellard75aadc22012-12-11 21:25:42 +00001//===-- R600Intrinsics.td - R600 Instrinsic defs -------*- tablegen -*-----===//
2//
3// The LLVM Compiler Infrastructure
4//
5// This file is distributed under the University of Illinois Open Source
6// License. See LICENSE.TXT for details.
7//
8//===----------------------------------------------------------------------===//
9//
10// R600 Intrinsic Definitions
11//
12//===----------------------------------------------------------------------===//
13
Matt Arsenault59bd3012016-01-22 19:00:09 +000014// FIXME: Should migrate to using TargetPrefix that matches triple arch name.
Tom Stellard75aadc22012-12-11 21:25:42 +000015let TargetPrefix = "R600", isTarget = 1 in {
Vincent Lejeuned3eed662013-05-17 16:50:20 +000016 class TextureIntrinsicFloatInput :
17 Intrinsic<[llvm_v4f32_ty], [
18 llvm_v4f32_ty, // Coord
19 llvm_i32_ty, // offset_x
20 llvm_i32_ty, // offset_y,
21 llvm_i32_ty, // offset_z,
22 llvm_i32_ty, // resource_id
23 llvm_i32_ty, // samplerid
24 llvm_i32_ty, // coord_type_x
25 llvm_i32_ty, // coord_type_y
26 llvm_i32_ty, // coord_type_z
27 llvm_i32_ty // coord_type_w
28 ], [IntrNoMem]>;
29 class TextureIntrinsicInt32Input :
30 Intrinsic<[llvm_v4i32_ty], [
31 llvm_v4i32_ty, // Coord
32 llvm_i32_ty, // offset_x
33 llvm_i32_ty, // offset_y,
34 llvm_i32_ty, // offset_z,
35 llvm_i32_ty, // resource_id
36 llvm_i32_ty, // samplerid
37 llvm_i32_ty, // coord_type_x
38 llvm_i32_ty, // coord_type_y
39 llvm_i32_ty, // coord_type_z
40 llvm_i32_ty // coord_type_w
41 ], [IntrNoMem]>;
42
Matt Arsenault59bd3012016-01-22 19:00:09 +000043 def int_R600_ldptr : TextureIntrinsicInt32Input;
44
Vincent Lejeunef143af32013-11-11 22:10:24 +000045 def int_R600_interp_const :
46 Intrinsic<[llvm_v4f32_ty], [llvm_i32_ty], [IntrNoMem]>;
Matt Arsenault59bd3012016-01-22 19:00:09 +000047 def int_R600_interp_xy :
Vincent Lejeunef143af32013-11-11 22:10:24 +000048 Intrinsic<[llvm_v2f32_ty], [llvm_i32_ty, llvm_float_ty, llvm_float_ty], [IntrNoMem]>;
Matt Arsenault59bd3012016-01-22 19:00:09 +000049 def int_R600_interp_zw :
Vincent Lejeunef143af32013-11-11 22:10:24 +000050 Intrinsic<[llvm_v2f32_ty], [llvm_i32_ty, llvm_float_ty, llvm_float_ty], [IntrNoMem]>;
Vincent Lejeune68501802013-02-18 14:11:19 +000051 def int_R600_load_texbuf :
52 Intrinsic<[llvm_v4f32_ty], [llvm_i32_ty, llvm_i32_ty], [IntrNoMem]>;
Tom Stellard6f1b8652013-01-23 21:39:49 +000053 def int_R600_store_swizzle :
54 Intrinsic<[], [llvm_v4f32_ty, llvm_i32_ty, llvm_i32_ty], []>;
Tom Stellard75aadc22012-12-11 21:25:42 +000055 def int_R600_store_stream_output :
Tom Stellardd8ac91d2013-01-23 21:39:47 +000056 Intrinsic<[], [llvm_v4f32_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], []>;
Tom Stellard75aadc22012-12-11 21:25:42 +000057 def int_R600_store_pixel_depth :
58 Intrinsic<[], [llvm_float_ty], []>;
59 def int_R600_store_pixel_stencil :
60 Intrinsic<[], [llvm_float_ty], []>;
Tom Stellardaf1bce72013-01-31 22:11:46 +000061 def int_R600_store_dummy :
62 Intrinsic<[], [llvm_i32_ty], []>;
Matt Arsenault59bd3012016-01-22 19:00:09 +000063} // End TargetPrefix = "R600", isTarget = 1
64
65let TargetPrefix = "r600", isTarget = 1 in {
66 def int_r600_tex : TextureIntrinsicFloatInput;
67 def int_r600_texc : TextureIntrinsicFloatInput;
68 def int_r600_txl : TextureIntrinsicFloatInput;
69 def int_r600_txlc : TextureIntrinsicFloatInput;
70 def int_r600_txb : TextureIntrinsicFloatInput;
71 def int_r600_txbc : TextureIntrinsicFloatInput;
72 def int_r600_txf : TextureIntrinsicInt32Input;
73 def int_r600_txq : TextureIntrinsicInt32Input;
74 def int_r600_ddx : TextureIntrinsicFloatInput;
75 def int_r600_ddy : TextureIntrinsicFloatInput;
Tom Stellard75aadc22012-12-11 21:25:42 +000076}