aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorJames Lyon <jamesly0n@hotmail.com>2013-04-26 16:42:12 +0100
committerJames Lyon <jamesly0n@hotmail.com>2013-04-26 16:42:12 +0100
commit6ee366e765483f6b48537d97fc81ae56f13d1b7f (patch)
treec9365133ee9c4cf1ec4fcee0641ac9adc2fe825d /include
parent41d76e1fcbe498b0d01e245f5a2d368a23760101 (diff)
downloadtinycc-6ee366e765483f6b48537d97fc81ae56f13d1b7f.tar.gz
tinycc-6ee366e765483f6b48537d97fc81ae56f13d1b7f.tar.bz2
Fixed x86-64 long double passing.
long double arguments require 16-byte alignment on the stack, which requires adjustment when the the stack offset is not an evven number of 8-byte words.
Diffstat (limited to 'include')
-rw-r--r--include/stdarg.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/stdarg.h b/include/stdarg.h
index 154030f..efca0e5 100644
--- a/include/stdarg.h
+++ b/include/stdarg.h
@@ -7,13 +7,13 @@
typedef void *va_list;
va_list __va_start(void *fp);
-void *__va_arg(va_list ap, int arg_type, int size);
+void *__va_arg(va_list ap, int arg_type, int size, int align);
va_list __va_copy(va_list src);
void __va_end(va_list ap);
#define va_start(ap, last) ((ap) = __va_start(__builtin_frame_address(0)))
#define va_arg(ap, type) \
- (*(type *)(__va_arg(ap, __builtin_va_arg_types(type), sizeof(type))))
+ (*(type *)(__va_arg(ap, __builtin_va_arg_types(type), sizeof(type), __alignof__(type))))
#define va_copy(dest, src) ((dest) = __va_copy(src))
#define va_end(ap) __va_end(ap)