Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(254)

Side by Side Diff: crosstest/test_arith.def

Issue 265703002: Add Om1 lowering with no optimizations (Closed) Base URL: https://gerrit.chromium.org/gerrit/p/native_client/pnacl-subzero.git@master
Patch Set: Merge changed from Karl's committed CL Created 6 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « crosstest/test_arith.cpp ('k') | crosstest/test_arith_frem.ll » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 #ifndef TEST_ARITH_DEF
2 #define TEST_ARITH_DEF
3
4 #define XSTR(s) STR(s)
5 #define STR(s) #s
6
7 #define UINTOP_TABLE \
8 /* inst, operator, div */ \
9 X(Add, +, 0 ) \
10 X(Sub, -, 0 ) \
11 X(Mul, *, 0 ) \
12 X(Udiv, /, 1 ) \
13 X(Urem, %, 1 ) \
14 X(Shl, <<, 0) \
15 X(Lshr, >>, 0) \
16 X(And, &, 0 ) \
17 X(Or, |, 0 ) \
18 X(Xor, ^, 0 ) \
19 //#define X(inst, op, isdiv)
20
21 #define SINTOP_TABLE \
22 /* inst, operator, div */ \
23 X(Sdiv, /, 1) \
24 X(Srem, %, 1) \
25 X(Ashr, >>, 0) \
26 //#define X(inst, op, isdiv)
27
28 #define COMMA ,
29 #define FPOP_TABLE \
30 /* inst, infix_op, func */ \
31 X(Fadd, +, ) \
32 X(Fsub, -, ) \
33 X(Fmul, *, ) \
34 X(Fdiv, /, ) \
35 X(Frem, COMMA, myFrem) \
36 //#define X(inst, op, func)
37
38 // Note: The above definition of COMMA, plus the "func" argument to
39 // the X macro, are because C++ does not allow the % operator on
40 // floating-point primitive types. To work around this, the expansion
41 // is "func(a infix_op b)", which becomes "myFrem(a , b)" for the Frem
42 // instruction and "(a + b)" for the Fadd instruction. The two
43 // versions of myFrem() are defined in a separate bitcode file.
44
45 #endif // TEST_ARITH_DEF
OLDNEW
« no previous file with comments | « crosstest/test_arith.cpp ('k') | crosstest/test_arith_frem.ll » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698