1 //===------------------------- unwind_06.cpp ------------------------------===//
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
7 //===----------------------------------------------------------------------===//
9 // UNSUPPORTED: libcxxabi-no-exceptions
16 // Compile with -Os to get compiler uses float registers to hold float variables
18 double get_(int x
) { return (double)x
; }
20 double (* volatile get
)(int) = get_
;
27 for (counter
= 100; counter
; counter
= counter
- 1)
37 for (counter
= 100; counter
; counter
= counter
- 1)
48 for (counter
= 100; counter
; counter
= counter
- 1)
49 a
+= get(1) + b
+ c
+ d
;
51 return get(0)+a
+b
+c
+d
;
60 for (counter
= 100; counter
; counter
= counter
- 1)
61 a
+= get(1) + b
+c
+d
+e
;
63 return get(0)+a
+b
+c
+d
+e
;
73 for (counter
= 100; counter
; counter
= counter
- 1)
74 a
+= get(1) + b
+c
+d
+e
+f
;
76 return get(0)+a
+b
+c
+d
+e
+f
;
87 for (counter
= 100; counter
; counter
= counter
- 1)
88 a
+= get(1) + b
+c
+d
+e
+f
+g
;
90 return get(0)+a
+b
+c
+d
+e
+f
+g
;
102 for (counter
= 100; counter
; counter
= counter
- 1)
103 a
+= get(1) + b
+c
+d
+e
+f
+g
+h
;
105 return get(0)+a
+b
+c
+d
+e
+f
+g
+h
;
108 double try8(bool v
) {
118 for (counter
= 100; counter
; counter
= counter
- 1)
119 a
+= get(1) + b
+c
+d
+e
+f
+g
+h
+i
;
121 return get(0)+a
+b
+c
+d
+e
+f
+g
+h
+i
;
250 return a
+b
+c
+d
+e
+f
+g
+h
;