Dan Gohman | f17a25c | 2007-07-18 16:29:46 +0000 | [diff] [blame] | 1 | ; fcfid and fctid should be generated when the 64bit feature is enabled, but not |
| 2 | ; otherwise. |
| 3 | |
Dan Gohman | da594cf | 2009-09-09 00:09:15 +0000 | [diff] [blame^] | 4 | ; RUN: llc < %s -march=ppc32 -mattr=+64bit | \ |
Dan Gohman | f17a25c | 2007-07-18 16:29:46 +0000 | [diff] [blame] | 5 | ; RUN: grep fcfid |
Dan Gohman | da594cf | 2009-09-09 00:09:15 +0000 | [diff] [blame^] | 6 | ; RUN: llc < %s -march=ppc32 -mattr=+64bit | \ |
Dan Gohman | f17a25c | 2007-07-18 16:29:46 +0000 | [diff] [blame] | 7 | ; RUN: grep fctidz |
Dan Gohman | da594cf | 2009-09-09 00:09:15 +0000 | [diff] [blame^] | 8 | ; RUN: llc < %s -march=ppc32 -mcpu=g5 | \ |
Dan Gohman | f17a25c | 2007-07-18 16:29:46 +0000 | [diff] [blame] | 9 | ; RUN: grep fcfid |
Dan Gohman | da594cf | 2009-09-09 00:09:15 +0000 | [diff] [blame^] | 10 | ; RUN: llc < %s -march=ppc32 -mcpu=g5 | \ |
Dan Gohman | f17a25c | 2007-07-18 16:29:46 +0000 | [diff] [blame] | 11 | ; RUN: grep fctidz |
Dan Gohman | da594cf | 2009-09-09 00:09:15 +0000 | [diff] [blame^] | 12 | ; RUN: llc < %s -march=ppc32 -mattr=-64bit | \ |
Dan Gohman | f17a25c | 2007-07-18 16:29:46 +0000 | [diff] [blame] | 13 | ; RUN: not grep fcfid |
Dan Gohman | da594cf | 2009-09-09 00:09:15 +0000 | [diff] [blame^] | 14 | ; RUN: llc < %s -march=ppc32 -mattr=-64bit | \ |
Dan Gohman | f17a25c | 2007-07-18 16:29:46 +0000 | [diff] [blame] | 15 | ; RUN: not grep fctidz |
Dan Gohman | da594cf | 2009-09-09 00:09:15 +0000 | [diff] [blame^] | 16 | ; RUN: llc < %s -march=ppc32 -mcpu=g4 | \ |
Dan Gohman | f17a25c | 2007-07-18 16:29:46 +0000 | [diff] [blame] | 17 | ; RUN: not grep fcfid |
Dan Gohman | da594cf | 2009-09-09 00:09:15 +0000 | [diff] [blame^] | 18 | ; RUN: llc < %s -march=ppc32 -mcpu=g4 | \ |
Dan Gohman | f17a25c | 2007-07-18 16:29:46 +0000 | [diff] [blame] | 19 | ; RUN: not grep fctidz |
| 20 | |
Tanya Lattner | 5ebaf3b | 2008-02-19 08:07:33 +0000 | [diff] [blame] | 21 | define double @X(double %Y) { |
| 22 | %A = fptosi double %Y to i64 ; <i64> [#uses=1] |
| 23 | %B = sitofp i64 %A to double ; <double> [#uses=1] |
| 24 | ret double %B |
Dan Gohman | f17a25c | 2007-07-18 16:29:46 +0000 | [diff] [blame] | 25 | } |
Tanya Lattner | 5ebaf3b | 2008-02-19 08:07:33 +0000 | [diff] [blame] | 26 | |