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.
|
|
|
|
|
2017-08-02 06:20:41 +08:00
|
|
|
; RUN: llc -verify-machineinstrs < %s -mattr=-vsx -mtriple=ppc32-- -mattr=+64bit | \
|
2007-04-16 05:17:45 +08:00
|
|
|
; RUN: grep fcfid
|
2017-08-02 06:20:41 +08:00
|
|
|
; RUN: llc -verify-machineinstrs < %s -mattr=-vsx -mtriple=ppc32-- -mattr=+64bit | \
|
2007-04-16 05:17:45 +08:00
|
|
|
; RUN: grep fctidz
|
2017-08-02 06:20:41 +08:00
|
|
|
; RUN: llc -verify-machineinstrs < %s -mattr=-vsx -mtriple=ppc32-- -mcpu=g5 | \
|
2007-04-16 05:17:45 +08:00
|
|
|
; RUN: grep fcfid
|
2017-08-02 06:20:41 +08:00
|
|
|
; RUN: llc -verify-machineinstrs < %s -mattr=-vsx -mtriple=ppc32-- -mcpu=g5 | \
|
2007-04-16 05:17:45 +08:00
|
|
|
; RUN: grep fctidz
|
2017-08-02 06:20:41 +08:00
|
|
|
; RUN: llc -verify-machineinstrs < %s -mattr=-vsx -mtriple=ppc32-- -mattr=-64bit | \
|
2007-04-16 05:17:45 +08:00
|
|
|
; RUN: not grep fcfid
|
2017-08-02 06:20:41 +08:00
|
|
|
; RUN: llc -verify-machineinstrs < %s -mattr=-vsx -mtriple=ppc32-- -mattr=-64bit | \
|
2007-04-16 05:17:45 +08:00
|
|
|
; RUN: not grep fctidz
|
2017-08-02 06:20:41 +08:00
|
|
|
; RUN: llc -verify-machineinstrs < %s -mattr=-vsx -mtriple=ppc32-- -mcpu=g4 | \
|
2007-04-16 05:17:45 +08:00
|
|
|
; RUN: not grep fcfid
|
2017-08-02 06:20:41 +08:00
|
|
|
; RUN: llc -verify-machineinstrs < %s -mattr=-vsx -mtriple=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
|
|
|
|