Hash :
dfe208f1
Author :
Date :
2021-04-28T18:26:00
Add loader for CL pass-through back end Bug: angleproject:5904 Change-Id: If4960f3150f6bbc85a30f0f6ac5c9e668e6ff756 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2864022 Commit-Queue: John Plate <jplate@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Cody Northrop <cnorthrop@google.com>
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 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50
//
// Copyright 2021 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
// validationCL.h: Validation functions for generic CL entry point parameters
#ifndef LIBANGLE_VALIDATIONCL_H_
#define LIBANGLE_VALIDATIONCL_H_
#include "libANGLE/CLCommandQueue.h"
#include "libANGLE/CLContext.h"
#include "libANGLE/CLDevice.h"
#include "libANGLE/CLEvent.h"
#include "libANGLE/CLKernel.h"
#include "libANGLE/CLMemory.h"
#include "libANGLE/CLPlatform.h"
#include "libANGLE/CLProgram.h"
#include "libANGLE/CLSampler.h"
#define ANGLE_CL_VALIDATE_VOID(EP, ...) \
do \
{ \
if (!Validate##EP(__VA_ARGS__)) \
{ \
return; \
} \
} while (0)
#define ANGLE_CL_VALIDATE_ERROR(EP, ...) \
do \
{ \
cl_int errorCode = Validate##EP(__VA_ARGS__); \
if (errorCode != CL_SUCCESS) \
{ \
return errorCode; \
} \
} while (0)
#define ANGLE_CL_VALIDATE_POINTER(EP, ...) \
do \
{ \
if (!Validate##EP(__VA_ARGS__)) \
{ \
return nullptr; \
} \
} while (0)
#endif // LIBANGLE_VALIDATIONCL_H_