S/390: Deprecate g5 and g6 CPU levels
[official-gcc.git] / liboffloadmic / runtime / compiler_if_target.h
blob9554238916c7a99e4686c7429f008b181fe64cb1
1 /*
2 Copyright (c) 2014-2015 Intel Corporation. All Rights Reserved.
4 Redistribution and use in source and binary forms, with or without
5 modification, are permitted provided that the following conditions
6 are met:
8 * Redistributions of source code must retain the above copyright
9 notice, this list of conditions and the following disclaimer.
10 * Redistributions in binary form must reproduce the above copyright
11 notice, this list of conditions and the following disclaimer in the
12 documentation and/or other materials provided with the distribution.
13 * Neither the name of Intel Corporation nor the names of its
14 contributors may be used to endorse or promote products derived
15 from this software without specific prior written permission.
17 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
18 "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
19 LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
20 A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
21 HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
22 SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
23 LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
24 DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
25 THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
26 (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
27 OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
31 /*! \file
32 \brief The interface between compiler-generated target code and runtime library
35 #ifndef COMPILER_IF_TARGET_H_INCLUDED
36 #define COMPILER_IF_TARGET_H_INCLUDED
38 #include "offload_target.h"
40 #define OFFLOAD_TARGET_ENTER OFFLOAD_PREFIX(target_enter)
41 #define OFFLOAD_TARGET_LEAVE OFFLOAD_PREFIX(target_leave)
42 #define OFFLOAD_TARGET_MAIN OFFLOAD_PREFIX(target_main)
44 /*! \fn OFFLOAD_TARGET_ENTER
45 \brief Fill in variable addresses using VarDesc array.
46 \brief Then call back the runtime library to fetch data.
47 \param ofld Offload descriptor created by runtime.
48 \param var_desc_num Number of variable descriptors.
49 \param var_desc Pointer to VarDesc array.
50 \param var_desc2 Pointer to VarDesc2 array.
52 extern "C" void OFFLOAD_TARGET_ENTER(
53 OFFLOAD ofld,
54 int var_desc_num,
55 VarDesc *var_desc,
56 VarDesc2 *var_desc2
59 /*! \fn OFFLOAD_TARGET_LEAVE
60 \brief Call back the runtime library to gather outputs using VarDesc array.
61 \param ofld Offload descriptor created by OFFLOAD_TARGET_ACQUIRE.
63 extern "C" void OFFLOAD_TARGET_LEAVE(
64 OFFLOAD ofld
67 // Entry point for the target application.
68 extern "C" void OFFLOAD_TARGET_MAIN(void);
70 #endif // COMPILER_IF_TARGET_H_INCLUDED