2007-04-16 05:17:45 +08:00
|
|
|
; fcfid and fctid should be generated when the 64bit feature is enabled, but not
|
2005-09-07 06:23:15 +08:00
|
|
|
; otherwise.
|
|
|
|
|
2014-10-17 09:41:22 +08:00
|
|
|
; RUN: llc < %s -mattr=-vsx -march=ppc32 -mattr=+64bit | \
|
2007-04-16 05:17:45 +08:00
|
|
|
; RUN: grep fcfid
|
2014-10-17 09:41:22 +08:00
|
|
|
; RUN: llc < %s -mattr=-vsx -march=ppc32 -mattr=+64bit | \
|
2007-04-16 05:17:45 +08:00
|
|
|
; RUN: grep fctidz
|
2014-10-17 09:41:22 +08:00
|
|
|
; RUN: llc < %s -mattr=-vsx -march=ppc32 -mcpu=g5 | \
|
2007-04-16 05:17:45 +08:00
|
|
|
; RUN: grep fcfid
|
2014-10-17 09:41:22 +08:00
|
|
|
; RUN: llc < %s -mattr=-vsx -march=ppc32 -mcpu=g5 | \
|
2007-04-16 05:17:45 +08:00
|
|
|
; RUN: grep fctidz
|
2014-10-17 09:41:22 +08:00
|
|
|
; RUN: llc < %s -mattr=-vsx -march=ppc32 -mattr=-64bit | \
|
2007-04-16 05:17:45 +08:00
|
|
|
; RUN: not grep fcfid
|
2014-10-17 09:41:22 +08:00
|
|
|
; RUN: llc < %s -mattr=-vsx -march=ppc32 -mattr=-64bit | \
|
2007-04-16 05:17:45 +08:00
|
|
|
; RUN: not grep fctidz
|
2014-10-17 09:41:22 +08:00
|
|
|
; RUN: llc < %s -mattr=-vsx -march=ppc32 -mcpu=g4 | \
|
2007-04-16 05:17:45 +08:00
|
|
|
; RUN: not grep fcfid
|
2014-10-17 09:41:22 +08:00
|
|
|
; RUN: llc < %s -mattr=-vsx -march=ppc32 -mcpu=g4 | \
|
2007-04-16 05:17:45 +08:00
|
|
|
; RUN: not grep fctidz
|
2005-09-07 06:23:15 +08:00
|
|
|
|
2008-02-19 16:07:33 +08:00
|
|
|
define double @X(double %Y) {
|
|
|
|
%A = fptosi double %Y to i64 ; <i64> [#uses=1]
|
|
|
|
%B = sitofp i64 %A to double ; <double> [#uses=1]
|
|
|
|
ret double %B
|
2005-09-07 06:23:15 +08:00
|
|
|
}
|
2008-02-19 16:07:33 +08:00
|
|
|
|