Mercurial > pub > dyncall > dyncall
comparison dyncall/dyncall_callvm_arm32_arm_armhf.c @ 466:ddfb9577a00e
introduced platform-native thiscall mode (DC_CALL_C_DEFAULT_THIS), as needed
for upcoming aggregate support (until now only x86 platforms allowed for
specifically selecting thiscall mode, given the different conventions on
the same platform); also added respective DC_SIGCHAR_CC_THISCALL ('*')
author | Tassilo Philipp |
---|---|
date | Wed, 02 Feb 2022 18:30:44 +0100 |
parents | ad5f9803f52f |
children | 71c884e610f0 |
comparison
equal
deleted
inserted
replaced
465:e2899b4ff713 | 466:ddfb9577a00e |
---|---|
4 Library: dyncall | 4 Library: dyncall |
5 File: dyncall/dyncall_callvm_arm32_arm_armhf.c | 5 File: dyncall/dyncall_callvm_arm32_arm_armhf.c |
6 Description: ARM 'armhf' ABI implementation | 6 Description: ARM 'armhf' ABI implementation |
7 License: | 7 License: |
8 | 8 |
9 Copyright (c) 2007-2020 Daniel Adler <dadler@uni-goettingen.de>, | 9 Copyright (c) 2007-2020 Daniel Adler <dadler@uni-goettingen.de>, |
10 Tassilo Philipp <tphilipp@potion-studios.com> | 10 Tassilo Philipp <tphilipp@potion-studios.com> |
11 | 11 |
12 Permission to use, copy, modify, and distribute this software for any | 12 Permission to use, copy, modify, and distribute this software for any |
13 purpose with or without fee is hereby granted, provided that the above | 13 purpose with or without fee is hereby granted, provided that the above |
14 copyright notice and this permission notice appear in all copies. | 14 copyright notice and this permission notice appear in all copies. |
26 | 26 |
27 #include "dyncall_callvm_arm32_arm_armhf.h" | 27 #include "dyncall_callvm_arm32_arm_armhf.h" |
28 #include "dyncall_alloc.h" | 28 #include "dyncall_alloc.h" |
29 | 29 |
30 | 30 |
31 /* | 31 /* |
32 ** arm32 armhf mode calling convention calls | 32 ** arm32 armhf mode calling convention calls |
33 ** | 33 ** |
34 ** - hybrid return-type call (bool ... pointer) | 34 ** - hybrid return-type call (bool ... pointer) |
35 ** | 35 ** |
36 ** Note the return type of this declaration is intentially of double-word size (despite | 36 ** Note the return type of this declaration is intentially of double-word size (despite |
37 ** the return value not being used in the code below). | 37 ** the return value not being used in the code below). |
209 DCCallVM_arm32_armhf* self = (DCCallVM_arm32_armhf*)in_self; | 209 DCCallVM_arm32_armhf* self = (DCCallVM_arm32_armhf*)in_self; |
210 DCCallVM_vt* vt; | 210 DCCallVM_vt* vt; |
211 | 211 |
212 switch(mode) { | 212 switch(mode) { |
213 case DC_CALL_C_DEFAULT: | 213 case DC_CALL_C_DEFAULT: |
214 case DC_CALL_C_DEFAULT_THIS: | |
214 case DC_CALL_C_ARM_ARMHF: | 215 case DC_CALL_C_ARM_ARMHF: |
215 vt = &vt_armhf; | 216 vt = &vt_armhf; |
216 break; | 217 break; |
217 case DC_CALL_C_ELLIPSIS: | 218 case DC_CALL_C_ELLIPSIS: |
218 case DC_CALL_C_ELLIPSIS_VARARGS: | 219 case DC_CALL_C_ELLIPSIS_VARARGS: |
219 vt = &vt_armhf_ellipsis; | 220 vt = &vt_armhf_ellipsis; |
220 break; | 221 break; |
221 default: | 222 default: |
222 self->mInterface.mError = DC_ERROR_UNSUPPORTED_MODE; | 223 self->mInterface.mError = DC_ERROR_UNSUPPORTED_MODE; |
223 return; | 224 return; |
224 } | 225 } |
225 dc_callvm_base_init(&self->mInterface, vt); | 226 dc_callvm_base_init(&self->mInterface, vt); |
226 } | 227 } |
227 | 228 |