@@ -70,7 +70,9 @@ class _LIBUNWIND_HIDDEN Registers_x86 {
70
70
void setVectorRegister (int num, v128 value);
71
71
static const char *getRegisterName (int num);
72
72
void jumpto () { __libunwind_Registers_x86_jumpto (this ); }
73
- static int lastDwarfRegNum () { return _LIBUNWIND_HIGHEST_DWARF_REGISTER_X86; }
73
+ static constexpr int lastDwarfRegNum () {
74
+ return _LIBUNWIND_HIGHEST_DWARF_REGISTER_X86;
75
+ }
74
76
static int getArch () { return REGISTERS_X86; }
75
77
76
78
uint32_t getSP () const { return _registers.__esp ; }
@@ -286,7 +288,9 @@ class _LIBUNWIND_HIDDEN Registers_x86_64 {
286
288
void setVectorRegister (int num, v128 value);
287
289
static const char *getRegisterName (int num);
288
290
void jumpto () { __libunwind_Registers_x86_64_jumpto (this ); }
289
- static int lastDwarfRegNum () { return _LIBUNWIND_HIGHEST_DWARF_REGISTER_X86_64; }
291
+ static constexpr int lastDwarfRegNum () {
292
+ return _LIBUNWIND_HIGHEST_DWARF_REGISTER_X86_64;
293
+ }
290
294
static int getArch () { return REGISTERS_X86_64; }
291
295
292
296
uint64_t getSP () const { return _registers.__rsp ; }
@@ -603,7 +607,9 @@ class _LIBUNWIND_HIDDEN Registers_ppc {
603
607
void setVectorRegister (int num, v128 value);
604
608
static const char *getRegisterName (int num);
605
609
void jumpto ();
606
- static int lastDwarfRegNum () { return _LIBUNWIND_HIGHEST_DWARF_REGISTER_PPC; }
610
+ static constexpr int lastDwarfRegNum () {
611
+ return _LIBUNWIND_HIGHEST_DWARF_REGISTER_PPC;
612
+ }
607
613
static int getArch () { return REGISTERS_PPC; }
608
614
609
615
uint64_t getSP () const { return _registers.__r1 ; }
@@ -1171,7 +1177,9 @@ class _LIBUNWIND_HIDDEN Registers_ppc64 {
1171
1177
void setVectorRegister (int num, v128 value);
1172
1178
static const char *getRegisterName (int num);
1173
1179
void jumpto ();
1174
- static int lastDwarfRegNum () { return _LIBUNWIND_HIGHEST_DWARF_REGISTER_PPC64; }
1180
+ static constexpr int lastDwarfRegNum () {
1181
+ return _LIBUNWIND_HIGHEST_DWARF_REGISTER_PPC64;
1182
+ }
1175
1183
static int getArch () { return REGISTERS_PPC64; }
1176
1184
1177
1185
uint64_t getSP () const { return _registers.__r1 ; }
@@ -1818,7 +1826,9 @@ class _LIBUNWIND_HIDDEN Registers_arm64 {
1818
1826
void setVectorRegister (int num, v128 value);
1819
1827
static const char *getRegisterName (int num);
1820
1828
void jumpto () { __libunwind_Registers_arm64_jumpto (this ); }
1821
- static int lastDwarfRegNum () { return _LIBUNWIND_HIGHEST_DWARF_REGISTER_ARM64; }
1829
+ static constexpr int lastDwarfRegNum () {
1830
+ return _LIBUNWIND_HIGHEST_DWARF_REGISTER_ARM64;
1831
+ }
1822
1832
static int getArch () { return REGISTERS_ARM64; }
1823
1833
1824
1834
uint64_t getSP () const { return _registers.__sp ; }
@@ -2108,7 +2118,9 @@ class _LIBUNWIND_HIDDEN Registers_arm {
2108
2118
restoreSavedFloatRegisters ();
2109
2119
restoreCoreAndJumpTo ();
2110
2120
}
2111
- static int lastDwarfRegNum () { return _LIBUNWIND_HIGHEST_DWARF_REGISTER_ARM; }
2121
+ static constexpr int lastDwarfRegNum () {
2122
+ return _LIBUNWIND_HIGHEST_DWARF_REGISTER_ARM;
2123
+ }
2112
2124
static int getArch () { return REGISTERS_ARM; }
2113
2125
2114
2126
uint32_t getSP () const { return _registers.__sp ; }
@@ -2608,7 +2620,9 @@ class _LIBUNWIND_HIDDEN Registers_or1k {
2608
2620
void setVectorRegister (int num, v128 value);
2609
2621
static const char *getRegisterName (int num);
2610
2622
void jumpto ();
2611
- static int lastDwarfRegNum () { return _LIBUNWIND_HIGHEST_DWARF_REGISTER_OR1K; }
2623
+ static constexpr int lastDwarfRegNum () {
2624
+ return _LIBUNWIND_HIGHEST_DWARF_REGISTER_OR1K;
2625
+ }
2612
2626
static int getArch () { return REGISTERS_OR1K; }
2613
2627
2614
2628
uint64_t getSP () const { return _registers.__r [1 ]; }
@@ -2805,7 +2819,9 @@ class _LIBUNWIND_HIDDEN Registers_mips_o32 {
2805
2819
void setVectorRegister (int num, v128 value);
2806
2820
static const char *getRegisterName (int num);
2807
2821
void jumpto ();
2808
- static int lastDwarfRegNum () { return _LIBUNWIND_HIGHEST_DWARF_REGISTER_MIPS; }
2822
+ static constexpr int lastDwarfRegNum () {
2823
+ return _LIBUNWIND_HIGHEST_DWARF_REGISTER_MIPS;
2824
+ }
2809
2825
static int getArch () { return REGISTERS_MIPS_O32; }
2810
2826
2811
2827
uint32_t getSP () const { return _registers.__r [29 ]; }
@@ -3132,7 +3148,9 @@ class _LIBUNWIND_HIDDEN Registers_mips_newabi {
3132
3148
void setVectorRegister (int num, v128 value);
3133
3149
static const char *getRegisterName (int num);
3134
3150
void jumpto ();
3135
- static int lastDwarfRegNum () { return _LIBUNWIND_HIGHEST_DWARF_REGISTER_MIPS; }
3151
+ static constexpr int lastDwarfRegNum () {
3152
+ return _LIBUNWIND_HIGHEST_DWARF_REGISTER_MIPS;
3153
+ }
3136
3154
static int getArch () { return REGISTERS_MIPS_NEWABI; }
3137
3155
3138
3156
uint64_t getSP () const { return _registers.__r [29 ]; }
@@ -3427,7 +3445,9 @@ class _LIBUNWIND_HIDDEN Registers_sparc {
3427
3445
void setVectorRegister (int num, v128 value);
3428
3446
static const char *getRegisterName (int num);
3429
3447
void jumpto ();
3430
- static int lastDwarfRegNum () { return _LIBUNWIND_HIGHEST_DWARF_REGISTER_SPARC; }
3448
+ static constexpr int lastDwarfRegNum () {
3449
+ return _LIBUNWIND_HIGHEST_DWARF_REGISTER_SPARC;
3450
+ }
3431
3451
static int getArch () { return REGISTERS_SPARC; }
3432
3452
3433
3453
uint64_t getSP () const { return _registers.__regs [UNW_SPARC_O6]; }
@@ -3611,7 +3631,7 @@ class _LIBUNWIND_HIDDEN Registers_sparc64 {
3611
3631
void setVectorRegister (int num, v128 value);
3612
3632
const char *getRegisterName (int num);
3613
3633
void jumpto ();
3614
- static int lastDwarfRegNum () {
3634
+ static constexpr int lastDwarfRegNum () {
3615
3635
return _LIBUNWIND_HIGHEST_DWARF_REGISTER_SPARC64;
3616
3636
}
3617
3637
static int getArch () { return REGISTERS_SPARC64; }
@@ -3796,7 +3816,9 @@ class _LIBUNWIND_HIDDEN Registers_hexagon {
3796
3816
void setVectorRegister (int num, v128 value);
3797
3817
const char *getRegisterName (int num);
3798
3818
void jumpto ();
3799
- static int lastDwarfRegNum () { return _LIBUNWIND_HIGHEST_DWARF_REGISTER_HEXAGON; }
3819
+ static constexpr int lastDwarfRegNum () {
3820
+ return _LIBUNWIND_HIGHEST_DWARF_REGISTER_HEXAGON;
3821
+ }
3800
3822
static int getArch () { return REGISTERS_HEXAGON; }
3801
3823
3802
3824
uint32_t getSP () const { return _registers.__r [UNW_HEXAGON_R29]; }
@@ -4009,7 +4031,9 @@ class _LIBUNWIND_HIDDEN Registers_riscv {
4009
4031
void setVectorRegister (int num, v128 value);
4010
4032
static const char *getRegisterName (int num);
4011
4033
void jumpto ();
4012
- static int lastDwarfRegNum () { return _LIBUNWIND_HIGHEST_DWARF_REGISTER_RISCV; }
4034
+ static constexpr int lastDwarfRegNum () {
4035
+ return _LIBUNWIND_HIGHEST_DWARF_REGISTER_RISCV;
4036
+ }
4013
4037
static int getArch () { return REGISTERS_RISCV; }
4014
4038
4015
4039
reg_t getSP () const { return _registers[2 ]; }
@@ -4295,7 +4319,9 @@ class _LIBUNWIND_HIDDEN Registers_ve {
4295
4319
void setVectorRegister (int num, v128 value);
4296
4320
static const char *getRegisterName (int num);
4297
4321
void jumpto ();
4298
- static int lastDwarfRegNum () { return _LIBUNWIND_HIGHEST_DWARF_REGISTER_VE; }
4322
+ static constexpr int lastDwarfRegNum () {
4323
+ return _LIBUNWIND_HIGHEST_DWARF_REGISTER_VE;
4324
+ }
4299
4325
static int getArch () { return REGISTERS_VE; }
4300
4326
4301
4327
uint64_t getSP () const { return _registers.__s [11 ]; }
@@ -4736,7 +4762,9 @@ class _LIBUNWIND_HIDDEN Registers_s390x {
4736
4762
void setVectorRegister (int num, v128 value);
4737
4763
static const char *getRegisterName (int num);
4738
4764
void jumpto ();
4739
- static int lastDwarfRegNum () { return _LIBUNWIND_HIGHEST_DWARF_REGISTER_S390X; }
4765
+ static constexpr int lastDwarfRegNum () {
4766
+ return _LIBUNWIND_HIGHEST_DWARF_REGISTER_S390X;
4767
+ }
4740
4768
static int getArch () { return REGISTERS_S390X; }
4741
4769
4742
4770
uint64_t getSP () const { return _registers.__gpr [15 ]; }
0 commit comments