aboutsummaryrefslogtreecommitdiff
path: root/gcc/config/rl78
diff options
context:
space:
mode:
authorSebastian Perta <sebastian.perta@renesas.com>2018-01-22 17:38:26 +0000
committerSebastian Perta <sebastianperta@gcc.gnu.org>2018-01-22 17:38:26 +0000
commitd975e494874f9cec2d59ac977cfc80260a773085 (patch)
treeca80a5f5323eca9224f3b9931571572aa727e5c6 /gcc/config/rl78
parentd10cff958f5e180817c088d3e80e9f22d1a8f172 (diff)
downloadgcc-d975e494874f9cec2d59ac977cfc80260a773085.zip
gcc-d975e494874f9cec2d59ac977cfc80260a773085.tar.gz
gcc-d975e494874f9cec2d59ac977cfc80260a773085.tar.bz2
rl78.md: New define_expand "smaxdi3".
2018-01-22 Sebastian Perta <sebastian.perta@renesas.com> * config/rl78/rl78.md: New define_expand "smaxdi3". 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com> * config/rl78/smaxdi3.S: New assembly file. * config/rl78/t-rl78: Added smaxdi3.S to LIB2ADD. From-SVN: r256953
Diffstat (limited to 'gcc/config/rl78')
-rw-r--r--gcc/config/rl78/rl78.md10
1 files changed, 10 insertions, 0 deletions
diff --git a/gcc/config/rl78/rl78.md b/gcc/config/rl78/rl78.md
index 92c63cf..b456737 100644
--- a/gcc/config/rl78/rl78.md
+++ b/gcc/config/rl78/rl78.md
@@ -728,3 +728,13 @@
"rl78_emit_libcall (\"__umaxdi3\", UMAX, DImode, DImode, 3, operands);
DONE;"
)
+
+(define_expand "smaxdi3"
+ [(set (match_operand:DI 0 "nonimmediate_operand" "")
+ (smax:DI (match_operand:DI 1 "general_operand" "")
+ (match_operand:DI 2 "general_operand" "")))
+ ]
+ "optimize_size"
+ "rl78_emit_libcall (\"__smaxdi3\", SMAX, DImode, DImode, 3, operands);
+ DONE;"
+)