FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
arrayfire/test/jit_test_api.cpp at master · arrayfire/arrayfire · GitHub
Uh oh!
There was an error while loading.
Please reload this page
.
arrayfire
/
arrayfire
Public
Notifications
You must be signed in to change notification settings
Fork
558
Star
4.9k
Code
Issues
292
Pull requests
26
Actions
Projects
Wiki
Security and quality
0
Insights
Additional navigation options
Code
Issues
Pull requests
Actions
Projects
Wiki
Security and quality
Insights
Expand file tree
Breadcrumbs
arrayfire
/
test
/
jit_test_api.cpp
Copy path
More file actions
More file actions
Latest commit
History
History
History
34 lines (29 loc) · 888 Bytes
Breadcrumbs
arrayfire
/
test
/
jit_test_api.cpp
Copy path
File metadata and controls
34 lines (29 loc) · 888 Bytes
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
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
/*
******************************************************
* Copyright (c) 2021, ArrayFire
* All rights reserved.
*
* This file is distributed under 3-clause BSD license.
* The complete license agreement can be obtained at:
* http://arrayfire.com/licenses/BSD-3-Clause
*******************************************************
*/
#
include
<
gtest/gtest.h
>
#
include
<
testHelpers.hpp
>
#
include
<
af/data.h
>
namespace
af
{
int
getMaxJitLen
(
void
);
void
setMaxJitLen
(
const
int
jitLen);
}
//
namespace af
TEST
(
JIT
, UnitMaxHeight) {
const
int
oldMaxJitLen =
af::getMaxJitLen
();
af::setMaxJitLen
(
1
);
af::array a =
af::constant
(
1
,
10
);
af::array b =
af::constant
(
2
,
10
);
af::array c = a * b;
af::array d = b * c;
c.
eval
();
d.
eval
();
af::setMaxJitLen
(oldMaxJitLen);
}
TEST
(
JIT
, ZeroMaxHeight) {
EXPECT_THROW
({
af::setMaxJitLen
(
0
); }, af::exception);
}
Back
|
FazBrowse Home
|
New Git URL