Wire Sysio
Wire Sysion 1.0.0
Loading...
Searching...
No Matches
bad_address.cpp
Go to the documentation of this file.
1
#include <
xbyak/xbyak.h
>
2
3
#define TEST_EXCEPTION(state) \
4
{ \
5
num++; \
6
bool exception = false; \
7
try { \
8
state; \
9
} catch (...) { \
10
exception = true; \
11
} \
12
if (!exception) { \
13
printf("exception should arise for %s\n", #state); \
14
err++; \
15
} \
16
}
17
18
struct
Code
:
Xbyak::CodeGenerator
{
19
Code
()
20
{
21
int
err = 0;
22
int
num = 0;
23
TEST_EXCEPTION
(
mov
(
eax
,
ptr
[
esp
+
esp
]));
24
TEST_EXCEPTION
(
mov
(
eax
,
ptr
[
ax
]));
// not support
25
TEST_EXCEPTION
(
mov
(
eax
,
ptr
[
esp
* 4]));
26
TEST_EXCEPTION
(
mov
(
eax
,
ptr
[
eax
* 16]));
27
TEST_EXCEPTION
(
mov
(
eax
,
ptr
[
eax
+
eax
+
eax
]));
28
TEST_EXCEPTION
(
mov
(
eax
,
ptr
[
eax
* 2 +
ecx
* 4]));
29
TEST_EXCEPTION
(
mov
(
eax
,
ptr
[
eax
* 2 +
ecx
* 4]));
30
TEST_EXCEPTION
(
vgatherdpd
(
xmm0
,
ptr
[
eax
* 2],
ymm3
));
31
TEST_EXCEPTION
(
vgatherdpd
(
xmm0
,
ptr
[
xmm0
+
xmm1
],
ymm3
));
32
#ifdef XBYAK64
33
TEST_EXCEPTION
(
mov
(
eax
,
ptr
[rax +
eax
]));
34
TEST_EXCEPTION
(
mov
(
eax
,
ptr
[
xmm0
+
ymm0
]));
35
#endif
36
if
(!err) {
37
printf(
"bad_address test %d ok\n"
, num);
38
}
39
}
40
};
41
42
int
main
()
43
{
44
Code
c;
45
}
main
int main()
Definition
bad_address.cpp:42
TEST_EXCEPTION
#define TEST_EXCEPTION(state)
Definition
bad_address.cpp:3
Xbyak::CodeGenerator
Definition
xbyak.h:1339
Xbyak::CodeGenerator::vgatherdpd
void vgatherdpd(const Xmm &x1, const Address &addr, const Xmm &x2)
Definition
xbyak.h:1005
Xbyak::CodeGenerator::ymm3
const Ymm ymm3
Definition
xbyak.h:2082
Xbyak::CodeGenerator::xmm1
const Xmm xmm1
Definition
xbyak.h:2081
Xbyak::CodeGenerator::esp
const Reg32 esp
Definition
xbyak.h:2087
Xbyak::CodeGenerator::eax
const Reg32 eax
Definition
xbyak.h:2087
Xbyak::CodeGenerator::ymm0
const Ymm ymm0
Definition
xbyak.h:2082
Xbyak::CodeGenerator::ecx
const Reg32 ecx
Definition
xbyak.h:2087
Xbyak::CodeGenerator::xmm0
const Xmm xmm0
Definition
xbyak.h:2081
Xbyak::CodeGenerator::mov
void mov(const Operand ®1, const Operand ®2)
Definition
xbyak.h:2210
Xbyak::CodeGenerator::ax
const Reg16 ax
Definition
xbyak.h:2088
Xbyak::CodeGenerator::ptr
const AddressFrame ptr
Definition
xbyak.h:2090
Code
Definition
bench.cpp:18
Code::Code
Code()
Definition
bad_address.cpp:19
xbyak.h
Xbyak ; JIT assembler for x86(IA32)/x64 by C++.
libraries
fc
libraries
ff
depends
xbyak
test
bad_address.cpp
Generated by
1.12.0