xref: /freebsd/contrib/llvm-project/clang/include/clang/Basic/BuiltinsBPF.td (revision 0fca6ea1d4eea4c934cfff25ac9ee8ad6fe95583)
1*0fca6ea1SDimitry Andric//===--- BuiltinsBPF.td - BPF Builtin function database ---------*- C++ -*-===//
2*0fca6ea1SDimitry Andric//
3*0fca6ea1SDimitry Andric// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4*0fca6ea1SDimitry Andric// See https://llvm.org/LICENSE.txt for license information.
5*0fca6ea1SDimitry Andric// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6*0fca6ea1SDimitry Andric//
7*0fca6ea1SDimitry Andric//===----------------------------------------------------------------------===//
8*0fca6ea1SDimitry Andric
9*0fca6ea1SDimitry Andricinclude "clang/Basic/BuiltinsBase.td"
10*0fca6ea1SDimitry Andric
11*0fca6ea1SDimitry Andric// Get record field information
12*0fca6ea1SDimitry Andricdef PreserveFieldInfo : TargetBuiltin {
13*0fca6ea1SDimitry Andric  let Spellings = ["__builtin_preserve_field_info"];
14*0fca6ea1SDimitry Andric  let Attributes = [CustomTypeChecking];
15*0fca6ea1SDimitry Andric  let Prototype = "unsigned int(...)";
16*0fca6ea1SDimitry Andric}
17*0fca6ea1SDimitry Andric
18*0fca6ea1SDimitry Andric// Get BTF type id
19*0fca6ea1SDimitry Andricdef BtfTypeID : TargetBuiltin {
20*0fca6ea1SDimitry Andric  let Spellings = ["__builtin_btf_type_id"];
21*0fca6ea1SDimitry Andric  let Attributes = [CustomTypeChecking];
22*0fca6ea1SDimitry Andric  let Prototype = "long unsigned int(...)";
23*0fca6ea1SDimitry Andric}
24*0fca6ea1SDimitry Andric
25*0fca6ea1SDimitry Andric// Get type information
26*0fca6ea1SDimitry Andricdef PreserveTypeInfo : TargetBuiltin {
27*0fca6ea1SDimitry Andric  let Spellings = ["__builtin_preserve_type_info"];
28*0fca6ea1SDimitry Andric  let Attributes = [CustomTypeChecking];
29*0fca6ea1SDimitry Andric  let Prototype = "long unsigned int(...)";
30*0fca6ea1SDimitry Andric}
31*0fca6ea1SDimitry Andric
32*0fca6ea1SDimitry Andric// Preserve enum value
33*0fca6ea1SDimitry Andricdef PreserveEnumValue : TargetBuiltin {
34*0fca6ea1SDimitry Andric  let Spellings = ["__builtin_preserve_enum_value"];
35*0fca6ea1SDimitry Andric  let Attributes = [CustomTypeChecking];
36*0fca6ea1SDimitry Andric  let Prototype = "long int(...)";
37*0fca6ea1SDimitry Andric}
38